Router(config-line)# session-timeout minutes [output]
The following command Sets an idle timeout interval on a console or terminal (tty) line.
Router(config-line)# absolute-timeout minutes
Sets a timeout interval on a virtual terminal (vty) line.
The following URL may help you:
http://www.cisco.com/en/US/docs/ios/12_2/termserv/configuration/guide/tcftrmop.html#wp1001125