Currently it appears that the Ketogenic Diet is safe to follow as a long term nutrition strategy. Very little research has been done on the long term effect of a Ketogenic Diet, but it appears it should produce no significant side effects.
Your goal for the Keto diet should determine the length of the time you maintain Keto. If you are following the Keto for any of the therapeutic applications it could be something you maintain for the rest of your life. If your goal is fat loss, mental clarity, or any other non therapeutic application, Keto might be a tool that you use off and on throughout your life.
In general, a Keto dietary approach can provide many health benefits and help keep certain diseases at bay so following it long term may be the best approach!