User add / delete in FreeBSD:-
Adding User
[root@fbsd ~]# adduser
Username: ajeesh
Full name: Ajeesh B Kannan
Uid (Leave empty for default):
Login group [ajeesh]:
Login group is ajeesh. Invite ajeesh into other groups? []: wheel
Login class [default]:
Shell (sh csh tcsh bash rbash nologin) [sh]: bash
Home directory [/home/ajeesh]:
Home directory permissions (Leave empty for default):
Use password-based authentication? [yes]:
Use an empty password? (yes/no) [no]:
Use a random password? (yes/no) [no]:
Enter password:
Enter password again:
Lock out the account after creation? [no]:
Username : ajeesh
Password : *****
Full Name : Ajeesh B Kannan
Uid : 1005
Class :
Groups : ajeesh wheel
Home : /home/ajeesh
Home Mode :
Shell : /usr/local/bin/bash
Locked : no
OK? (yes/no): yes
adduser: INFO: Successfully added (ajeesh) to the user database.
Add another user? (yes/no): no
Goodbye!
Delete user:-
[root@fbsd ~]# rmuser
Please enter one or more usernames: jack
Matching password entry:
jack:*:1006:1006::0:0:jack T:/home/jack:/bin/sh
Is this the entry you wish to remove? y
Remove user's home directory (/home/jack)? y
Removing user (jack): processes(2) mailspool home passwd.
1. Screen Install
[root@fbsd ~]# cd /usr/ports/sysutils/screen
[root@fbsd ~]# make install clean
2. Bash Shell
#cd /usr/ports/shells/bash
#make install clean
To make bash as default shell
# chsh -s /usr/local/bin/bash root(or your required username)
To check whether bash is installed
#finger root(or your required username)
2. Installing and configuring PURE-FTP on Free BSD
cd /usr/ports
1. make search name=pure-ftp :- find out the port
2. # make config
3. # make install clean
4. # cd /usr/local/etc
5. # cp pure-ftpd.conf.sample pure-ftpd.conf
6. # chmod 644 pure-ftpd.conf
7. # ee pure-ftpd.conf
VerboseLog yes
PureDB /usr/local/etc/pureftpd.pdb
CreateHomeDir yes
8. # pure-pwconvert >> /usr/local/etc/pureftpd.passwd
9. # chmod 600 /usr/local/etc/pureftpd.passwd
10.# pure-pw mkdb
11.# pw useradd vftp -s /sbin/nologin -w no -d /usr/home/vftp? -c "Virtual FTP user" -m
12.# pure-pw useradd ajeesh -u vftp -g vftp -d /usr/home/vftp/ajeesh
13.# pure-pw mkdb
14.# /usr/local/etc/rc.d/pure-ftpd onestart
once you add pureftpd_enable="YES" on /etc/rc.conf you can restart pure-ftp
# /usr/local/etc/rc.d/pure-ftpd restart
# /usr/local/etc/rc.d/pure-ftpd status
No comments:
Post a Comment