The only safe and yet effective nootropic that comes into my mind is modafinil. However, there are some things you need to keep in mind with it. Although it can indeed help you sleep less, and it will help with focus, it will not help you get more disciplined.
Let's put it this way - if your studies are struggling because you are spending too much time on facebook, you will only spend this time on facebook more focused. So modafinil will not change your habbits. Also, due to the increased focus it can cause what some call tunnel thinking.
Therefore, I would rather suggest you to have a well organized day, have enough sleep, and eat well - all these things will help you big time with exams. I know that, I have two degrees and speak 5 languages - I know about exams.