Hey
if its for the server you logged in into then use the following command, hope it'll help you out !!
prtconf
for more options of this command, please refer to "man prtconf".
Or as era said "last" will be efficient to do your task over.
Thanks
Varun Gupta