# Logging in automatically



## MHA152 (Aug 11, 2013)

Hello.

How can I log in automatically into my user at startup?


----------



## wblock@ (Aug 11, 2013)

Here is one way: http://forums.freebsd.org/showpost.php?p=125992&postcount=6.


----------



## MHA152 (Aug 11, 2013)

I do, this works. Open /etc/gettytab and add these lines:


```
# WB: autologin console as user mha
A|Al|Autologin console:\
        :ht:np:sp#115200:al=mha
```

and save that, then open /etc/ttys and change this line
	
	



```
ttyv0	"/usr/libexec/getty Pc"		xterm	on  secure
```
 to this line 
	
	



```
ttyv0	"/usr/libexec/getty Al"		xterm	on  secure
```
My username is "mha" Is the above true?


----------



## wblock@ (Aug 11, 2013)

Looks right.  That will just log in to the shell.


----------



## MHA152 (Aug 11, 2013)

I reboot my system and it works. *T*he question has been solved, thank you for helping me.


----------

