| /l3/users/11-03-2008/nt-ladm/debian1.unix.nt/root :1 :2 :3 :4 :5 :6 :7 :8 :9 :10 :11 :12 :13 :14 :15 :16 :17 | 
    
  | 
    
| 
 #ssh 192.168.16.25 
[root@debian1:~]# ssh 192.168.16.25 -l
Password:
Password:
Password:
Permission denied (publickey,keyboard-interactive).
Password:
Last login: Fri Mar 14 08:07:44 2008
Copyright (c) 1980, 1983, 1986, 1988, 1990, 1991, 1993, 1994
        The Regents of the University of California.  All rights reserved.
FreeBSD 7.0-CURRENT-200710 (GENERIC) #0: Thu Oct 11 06:53:50 UTC 2007
...
   http://www.FreeBSD.org/search/.  If the doc distribution has
   been installed, they're also available formatted in /usr/share/doc.
If you still have a question or problem, please take the output of
`uname -a', along with any relevant error messages, and email it
as a question to the questions@FreeBSD.org mailing list.  If you are
unfamiliar with FreeBSD's directory layout, please refer to the hier(7)
manual page.  If you are not familiar with manual pages, type `man man'.
You may also use sysinstall(8) to re-enter the installation and
configuration utility.  Edit /etc/motd to change this login announcement.
Removing stale pidfile
 | 
| 
 #vim /etc/
 
 
 | 
| 
 #exit
 
 
Connection to 192.168.16.25 closed.  | 
| 
 #vim /etc/ssh/sshd_config 
 | 
| 
 #vim /etc/passwd 
 | 
| 
 #vim /etc/shadow 
 | 
| 
 #ssh 192.168.16.25 -l root 
Password:
Password:
Last login: Fri Mar 14 08:14:02 2008 from 192.168.16.1
Copyright (c) 1980, 1983, 1986, 1988, 1990, 1991, 1993, 1994
        The Regents of the University of California.  All rights reserved.
FreeBSD 7.0-CURRENT-200710 (GENERIC) #0: Thu Oct 11 06:53:50 UTC 2007
Welcome to FreeBSD!
Before seeking technical support, please use the following resources:
o  Security advisories and updated errata information for all releases are
   at http://www.FreeBSD.org/releases/ - always consult the ERRATA section
...
   http://www.FreeBSD.org/search/.  If the doc distribution has
   been installed, they're also available formatted in /usr/share/doc.
If you still have a question or problem, please take the output of
`uname -a', along with any relevant error messages, and email it
as a question to the questions@FreeBSD.org mailing list.  If you are
unfamiliar with FreeBSD's directory layout, please refer to the hier(7)
manual page.  If you are not familiar with manual pages, type `man man'.
You may also use sysinstall(8) to re-enter the installation and
configuration utility.  Edit /etc/motd to change this login announcement.
Removing stale pidfile
 | 
| 
 #man master.passwd 
 | 
| 
 #ls -l /etc/passwd 
[root@fbsd5:~]# ls -l /etc/master.passwd -rw------- 1 root wheel 1930 Mar 14 08:13 /etc/master.passwd -rw-r--r-- 1 root wheel 1696 Mar 14 08:13 /etc/passwd  | 
| 
 #exit
 
 
[root@fbsd5:~]# vim Connection to 192.168.16.25 closed.  | 
| 
 #vim /etc/passwd 
 | 
| 
 #vim /etc/group 
 | 
| 
 #vim /etc/passwd 
 | 
| 
 #vim /etc/shadow 
 | 
| 
 #useradd -h
 
 
useradd: invalid option -- h
Usage: useradd [options] LOGIN
Options:
  -b, --base-dir BASE_DIR       base directory for the new user account
                                home directory
  -c, --comment COMMENT         set the GECOS field for the new user account
  -d, --home-dir HOME_DIR       home directory for the new user account
  -D, --defaults                print or save modified default useradd
                                configuration
  -e, --expiredate EXPIRE_DATE  set account expiration date to EXPIRE_DATE
...
  -K, --key KEY=VALUE           overrides /etc/login.defs defaults
  -m, --create-home             create home directory for the new user
                                account
  -o, --non-unique              allow create user with duplicate
                                (non-unique) UID
  -p, --password PASSWORD       use encrypted password for the new user
                                account
  -r, --system                  create a system account
  -s, --shell SHELL             the login shell for the new user account
  -u, --uid UID                 force use the UID for the new user account
 | 
| 
 #useradd -d
 
 
 | 
| 
 #man bash 
 | 
| 
 #man crypt
 
 
 | 
| 
 #apropos crypt 
gpg (1) - OpenPGP encryption and signing tool shadow (5) - encrypted password file  | 
| 
 #whatis intro 
intro (7) - Introduction to overview, conventions, and miscellany section intro (4) - Introduction to special files intro (1) - Introduction to user commands intro (8) - Introduction to administration and privileged commands intro (2) - Introduction to system calls intro (6) - Introduction to games intro (5) - Introduction to file formats intro (3) - Introduction to library functions  | 
| 
 #man 3 crypt
 
 
 | 
| 
 #apt-cache sea 
libqca1c2 - Qt Cryptographic Architecture - shared library libsha-ocaml - SHA cryptographic hash functions for OCaml libsha-ocaml-dev - SHA cryptographic hash functions for OCaml libssl-dev - SSL development libraries, header files and documentation libssl-ocaml - OCaml bindings for OpenSSL libssl-ocaml-dev - OCaml bindings for OpenSSL libssl0.9.7 - SSL shared libraries libssl0.9.7-dbg - Symbol tables for libssl and libcrypt libssl0.9.8 - SSL shared libraries libssl0.9.8-dbg - Symbol tables for libssl and libcrypt ... vtun - Virtual Tunnel over TCP/IP Networks whois - the GNU whois client wlassistant - User friendly KDE frontend for wireless network connection xmlsec1 - XML security command line processor xpdf-reader - Portable Document Format (PDF) suite -- viewer for X11 yardradius - YARD Radius Auth/Acct Server zip - Archiver for .zip files znc - an advanced IRC bouncer zope-passwordresettool - password reset tool for Plone zsafe - Password manager with encryption  | 
| 
 #useradd -h
 
 
useradd: invalid option -- h
Usage: useradd [options] LOGIN
Options:
  -b, --base-dir BASE_DIR       base directory for the new user account
                                home directory
  -c, --comment COMMENT         set the GECOS field for the new user account
  -d, --home-dir HOME_DIR       home directory for the new user account
  -D, --defaults                print or save modified default useradd
                                configuration
  -e, --expiredate EXPIRE_DATE  set account expiration date to EXPIRE_DATE
...
  -K, --key KEY=VALUE           overrides /etc/login.defs defaults
  -m, --create-home             create home directory for the new user
                                account
  -o, --non-unique              allow create user with duplicate
                                (non-unique) UID
  -p, --password PASSWORD       use encrypted password for the new user
                                account
  -r, --system                  create a system account
  -s, --shell SHELL             the login shell for the new user account
  -u, --uid UID                 force use the UID for the new user account
 | 
| 
 #useradd -c "Mega super user"
 
 
 | 
| 
 #useradd -h
 
 
[root@debian1:~]# ssh clint@192.168.16.254 clint@192.168.16.254's password: Linux debian 2.6.18.8-xen #3 SMP Sun Feb 17 12:07:10 UTC 2008 i686 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Thu Mar 13 20:40:15 2008 from debian.unix.nt clint@debian:~$ sudo iptables -t nat -n -L ... -K, --key KEY=VALUE overrides /etc/login.defs defaults -m, --create-home create home directory for the new user account -o, --non-unique allow create user with duplicate (non-unique) UID -p, --password PASSWORD use encrypted password for the new user account -r, --system create a system account -s, --shell SHELL the login shell for the new user account -u, --uid UID force use the UID for the new user account  | 
| 
 #useradd -c "mega user" -d /home/mega -k /etc/skel -m -p { } -s /b
 
 
bin/ boot/  | 
| 
 ##
 
 
 | 
| 
 #cd /etc/skel/ 
 | 
| 
 #ls 
 | 
| 
 #ls -la 
итого 20 drwxr-xr-x 2 root root 4096 2007-12-23 16:31 . drwxr-xr-x 56 root root 4096 2008-03-14 10:30 .. -rw-r--r-- 1 root root 220 2006-12-11 23:20 .bash_logout -rw-r--r-- 1 root root 414 2006-12-11 23:20 .bash_profile -rw-r--r-- 1 root root 2227 2006-12-11 23:20 .bashrc  | 
| 
 #touch testfile 
 | 
| 
 #ls 
testfile  | 
| 
 #cd 
 | 
| 
 #apt-get install crypt
 
 
Чтение списков пакетов... Готово Построение дерева зависимостей... Готово E: Не могу найти пакет crypt  | 
| 
 #apt-cache search crypt | less 
 | 
| 
 #apt-get install grub 
Чтение списков пакетов... Готово Построение дерева зависимостей... Готово Предлагаемые пакеты: grub-doc mdadm НОВЫЕ пакеты, которые будут установлены: grub обновлено 0, установлено 1 новых пакетов, для удаления отмечено 0 пакетов, и 32 пакетов не обновлено. Необходимо скачать 375kБ архивов. После распаковки объем занятого дискового пространства возрастёт на 823kB. Получено:1 http://debian.org.ua etch/main grub 0.97-27 [375kB] Получено 375kB за 5s (71,1kB/c) Выбор ранее не выбранного пакета grub. (Чтение базы данных... на данный момент установлено 22509 файлов и каталогов.) Распаковывается пакет grub (из файла .../archives/grub_0.97-27_i386.deb)... Настраивается пакет grub (0.97-27) ...  | 
| 
 #grub-md5-crypt 
Password: Retype password: $1$nxmhP$rJBYf99qyrf3OLWBRaLRB/  | 
| 
 #useradd -c "mega user" -d /home/mega -k /etc/skel -m -p "$1$nxmhP$rJBYf99qyrf3OLWBRaLRB/" -s /bin/bash mega 
 | 
| 
 #w 
10:57:40 up 1 day, 1:33, 7 users, load average: 0,01, 0,01, 0,00 USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT root ttyp0 debian5.unix.nt Thu09 1:11 0.18s 0.00s script -f -q /root/.lilalo//2410215131319712535-1205394528.script root ttyp2 debian14.unix.nt 10:07 9:23m 0.10s 0.01s script -f -q /root/.lilalo//2728622729479331318-1205482051.script root ttyp6 debian9.unix.nt Thu09 49:23m 0.15s 0.00s script -f -q /root/.lilalo//27525254842013527700-1205395148.script root ttypa 192.168.16.204 Thu10 1:11 0.22s 0.01s script -f -q /root/.lilalo//2087529520308728444-1205395350.script root ttypc debian6.unix.nt Thu10 1:11 0.13s 0.01s script -f -q /root/.lilalo//24451179528163772-1205395357.script root ttype :ttyp5:S.0 09:45 0.00s 0.03s 0.01s script -f -q /root/.lilalo//1328830691356716332-1205480752.script root ttyp4 debian.unix.nt 09:45 0.00s 0.05s 0.00s script -f -q /root/.lilalo//27459278982665410200-1205480748.script  | 
| 
 #ssh 127.0.0.1 -l mega
 
 
mega@127.0.0.1's password: Permission denied, please try again. mega@127.0.0.1's password: Permission denied, please try again. mega@127.0.0.1's password: Permission denied (publickey,password).  | 
| 
 #useradd -c "mega user" -d /home/mega -k /etc/skel -m -p "$1$nxmhP$rJBYf99qyrf3OLWBRaLRB/"
 
 
 | 
| 
 #vim /etc/shadow 
 | 
| 
 #useradd -c "mega user" -d /home/mega -k /etc/skel -m -p \$1\$nxmhP\$rJBYf99qyrf3OLWBRaLRB\
 
 
useradd: пользователь mega существует  | 
| 
 #userdel -h
 
 
Использование: userdel [параметры] ИМЯ Параметры: -f, --force удалять файлы, даже если они не принадлежат пользователю -h, --help показать данное сообщение и закончить работу -r, --remove удалить домашний каталог и почтовый ящик  | 
| 
 #userdel -r mega 
 | 
| 
 #vim /etc/shadow 
 | 
| 
 #ssh 127.0.0.1 -l mega 
mega@127.0.0.1's password: Linux debiant 2.6.18-5-xen-686 #1 SMP Fri Jun 1 05:05:24 UTC 2007 i686 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. mega@debian1:~$ exit logout Connection to 127.0.0.1 closed.  | 
| 
 #vim /etc/default/useradd 
 | 
| 
 #vim /etc/default/useradd
 
 
 | 
| 
 #adduser
 
 
adduser: Можно указать только одно или два имени.  | 
| 
 #adduser mega1
 
 
Добавляется пользователь `mega1' ...
Добавляется новая группа `mega1' (1203) ...
Добавляется новый пользователь `mega1' (1203) в группу `mega1' ...
Создаётся домашний каталог `/home/mega1' ...
Копирование файлов из `/etc/skel' ...
Enter new UNIX password:
Retype new UNIX password:
No password supplied
Enter new UNIX password:
Retype new UNIX password:
No password supplied
Enter new UNIX password:
Retype new UNIX password:
No password supplied
passwd: Authentication token manipulation error
passwd: password unchanged
Попробовать ещё раз? [Д/н] n
Изменение информации о пользователе mega1
Введите новое значение или нажмите ВВОД для выбора значения по умолчанию
        Полное имя []: adduser: `/usr/bin/chfn mega1' завершился по сигналу 2. Завершение работы.
 | 
| 
 #adduser mega1
 
 
[root@debian1:~]# ssh 127.0.0.1 -l mega mega@127.0.0.1's password: Linux debiant 2.6.18-5-xen-686 #1 SMP Fri Jun 1 05:05:24 UTC 2007 i686 The programs included with the Debian GNU/Linux system are free software; the exact distribution terms for each program are described in the individual files in /usr/share/doc/*/copyright. Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent permitted by applicable law. Last login: Fri Mar 14 10:59:23 2008 from 127.0.0.1 mega@debian1:~$ ls testfile mega@debian1:~$ exit logout Connection to 127.0.0.1 closed. adduser: Пользователь `mega1' уже существует.  | 
| 
 #vim /etc/passwd 
 | 
| 
 #userdel -r mega1 
 | 
| 
 #del
 
 
delgroup deluser  | 
| 
 #deluser -h 
deluser ÐÐÐÑÑ Ð·Ð°Ð¿Ð¸ÑÑ Ð¿Ð¾Ð»ÑзоваÑÐµÐ»Ñ Ð¸Ð· ÑиÑÑемÑ
  пÑимеÑ: deluser mike
  --remove-home             ÑдалиÑÑ Ð´Ð¾Ð¼Ð°Ñний каÑалог полÑзоваÑелÑ
                            и поÑÑовÑй ÑÑик
  --remove-all-files        ÑдалиÑÑ Ð²Ñе ÑÐ°Ð¹Ð»Ñ Ð¿ÑинадлежаÑие полÑзоваÑелÑ
  --backup                  ÑделаÑÑ ÑезеÑвнÑе копии Ñайлов пеÑед Ñдалением.
  --backup-to <ÐÐТ>         каÑалог Ð´Ð»Ñ ÑезеÑвнÑÑ
 копий Ñайлов.
                            Ðо ÑмолÑÐ°Ð½Ð¸Ñ Ð¸ÑполÑзÑеÑÑÑ ÑекÑÑий каÑалог.
  --system                  ÑдалиÑÑ ÑолÑко еÑли ÑÑÑÑÐ½Ð°Ñ Ð·Ð°Ð¿Ð¸ÑÑ ÑиÑÑемнаÑ
delgroup ÐРУÐÐÐ
...
  пÑимеÑ: deluser --group students
  --system                  ÑдалиÑÑ ÑолÑко еÑли гÑÑппа ÑиÑÑемнаÑ
  --only-if-empty           ÑдалиÑÑ, ÑолÑко еÑли в ней Ð½ÐµÑ Ð¿Ð¾Ð»ÑзоваÑелей
deluser ÐÐÐаÑÐµÐ»Ñ Ð¸Ð· гÑÑппÑ
  пÑимеÑ: deluser mike students
обÑие паÑамеÑÑÑ:
  --quiet | -q              не вÑводиÑÑ Ð¸Ð½ÑоÑмаÑÐ¸Ñ Ð¿Ñи ÑабоÑе в stdout
  --help | -h               показаÑÑ ÑпÑÐ°Ð²ÐºÑ Ð¾Ð± иÑполÑзовании
  --version | -v            показаÑÑ Ð²ÐµÑÑÐ¸Ñ Ð¸ авÑоÑÑкие пÑава
  --conf | -c ФÐÐконÑигÑÑаÑионного
 | 
| 
 #deluser --remove-home mega2 
Идёт поиск файлов для сохранения/удаления ... Удаляются файлы ... Удаляется пользователь `mega2' ... Готово.  | 
| 
 #vim /etc/default/
 
 
 | 
| 
 #vim /etc/default/
 
 
 | 
| 
 #chfn -h
 
 
chfn: option requires an argument -- h
Использование: chfn [-f полное имя] [-r номер комнаты] [-w рабочий телефон]
        [-h домашний телефон] [-o другое] [имя пользователя]
 | 
| 
 #addgroup -h 
adduser [--home ÐÐТ] [--shell ÐÐÐÐ--no-create-home] [--uid ID]
[--firstuid ID] [--lastuid ID] [--gecos GECOS] [--ingroup ÐРУÐÐÐ | --gid ID]
[--disabled-password] [--disabled-login] ÐÐÐзоваÑелÑ
adduser --system [--home ÐÐТ] [--shell ÐÐÐÐ--no-create-home] [--uid ID]
[--gecos GECOS] [--group | --ingroup ÐРУÐÐÐ | --gid ID] [--disabled-password]
[--disabled-login] ÐÐолÑзоваÑелÑ
adduser --group [--gid ID] ÐРУÐÐÐ
addgroup [--gid ID] ÐРУÐÐÐ
   ÐобавиÑÑ Ð¿Ð¾Ð»ÑзоваÑелÑÑкÑÑ Ð³ÑÑппÑ
addgroup --system [--gid ID] ÐРУÐÐÐ
   ÐобавиÑÑ ÑиÑÑемнÑÑ Ð³ÑÑппÑ
adduser ÐÐÐвÑÑÑего полÑзоваÑÐµÐ»Ñ Ð² ÑÑÑеÑÑвÑÑÑÑÑ Ð³ÑÑппÑ
обÑие паÑамеÑÑÑ:
  --quiet | -q              не вÑводиÑÑ Ð¸Ð½ÑоÑмаÑÐ¸Ñ Ð¿Ñи ÑабоÑе в stdout
  --force-badname           ÑазÑеÑиÑÑ Ð¸Ð¼ÐµÐ½Ð° полÑзоваÑелей, коÑоÑÑе не
                            ÑдовлеÑвоÑÑÑÑ ÐºÐ¾Ð½ÑигÑÑаÑионной пеÑеменной
                            NAME_REGEX
  --help | -h               показаÑÑ ÑпÑÐ°Ð²ÐºÑ Ð¾Ð± иÑполÑзовании
  --version | -v            показаÑÑ Ð²ÐµÑÑÐ¸Ñ Ð¸ авÑоÑÑкие пÑава
  --conf | -c ФÐÐконÑигÑÑаÑионного
 | 
| 
 #addgroup testgroup 
Добавляется группа `testgroup' (GID 1203) ... Готово.  | 
| 
 #usermod -h
 
 
Usage: usermod [options] LOGIN
Options:
  -c, --comment COMMENT         new value of the GECOS field
  -d, --home HOME_DIR           new home directory for the user account
  -e, --expiredate EXPIRE_DATE  set account expiration date to EXPIRE_DATE
  -f, --inactive INACTIVE       set password inactive after expiration
                                to INACTIVE
  -g, --gid GROUP               force use GROUP as new primary group
  -G, --groups GROUPS           new list of supplementary GROUPS
  -a, --append          append the user to the supplemental GROUPS
...
  -h, --help                    display this help message and exit
  -l, --login NEW_LOGIN         new value of the login name
  -L, --lock                    lock the user account
  -m, --move-home               move contents of the home directory to the new
                                location (use only with -d)
  -o, --non-unique              allow using duplicate (non-unique) UID
  -p, --password PASSWORD       use encrypted password for the new password
  -s, --shell SHELL             new login shell for the user account
  -u, --uid UID                 new UID for the user account
  -U, --unlock                  unlock the user account
 | 
| 
 #usermod -G testgroup root 
 | 
| 
 #id 
uid=0(root) gid=0(root) группы=0(root)  | 
| 
 #useradd -c "mega user" -d /home/mega -k /etc/skel -m -p \$1\$nxmhP\$rJBYf99qyrf3OLWBRaLRB\/ -s /bin/bash mega
 
 
useradd: пользователь mega существует  | 
| 
 #usermod -G testgroup mega 
 | 
| 
 #id mega 
uid=1202(mega) gid=1202(mega) группы=1202(mega),1203(testgroup)  | 
| 
 #vim /etc/group 
--- /tmp/l3-saved-8797.10290.22544 2008-03-14 11:08:05.000000000 +0200 +++ /etc/group 2008-03-14 11:08:13.000000000 +0200 @@ -19,7 +19,7 @@ floppy:x:25: tape:x:26: sudo:x:27: -audio:x:29: +audio:x:29:mega dip:x:30: www-data:x:33: backup:x:34:  | 
| 
 #id mega 
uid=1202(mega) gid=1202(mega) группы=1202(mega),29(audio),1203(testgroup)  | 
| 
 #delgroup testgruop
 
 
Группа `testgruop' не существует.  | 
| 
 #delgroup testgroup 
Удаляется группа `testgroup' ... Готово.  | 
| 
 #ssh 192.168.16.25 
Password:
Last login: Fri Mar 14 08:21:23 2008 from 192.168.16.1
Copyright (c) 1980, 1983, 1986, 1988, 1990, 1991, 1993, 1994
        The Regents of the University of California.  All rights reserved.
FreeBSD 7.0-CURRENT-200710 (GENERIC) #0: Thu Oct 11 06:53:50 UTC 2007
Welcome to FreeBSD!
Before seeking technical support, please use the following resources:
o  Security advisories and updated errata information for all releases are
   at http://www.FreeBSD.org/releases/ - always consult the ERRATA section
   for your release first as it's updated frequently.
...
   http://www.FreeBSD.org/search/.  If the doc distribution has
   been installed, they're also available formatted in /usr/share/doc.
If you still have a question or problem, please take the output of
`uname -a', along with any relevant error messages, and email it
as a question to the questions@FreeBSD.org mailing list.  If you are
unfamiliar with FreeBSD's directory layout, please refer to the hier(7)
manual page.  If you are not familiar with manual pages, type `man man'.
You may also use sysinstall(8) to re-enter the installation and
configuration utility.  Edit /etc/motd to change this login announcement.
Removing stale pidfile
 | 
| 
 #whereis adduser 
[root@fbsd5:~]# adduser Username: testuser Full name: TEST USER Uid (Leave empty for default): Login group [testuser]: wheel Login group is wheel. Invite testuser into other groups? []: audio Group audio does not exist! Login group is wheel. Invite testuser into other groups? []: src Group src does not exist! Login group is wheel. Invite testuser into other groups? []: disk ... Class : russian Groups : wheel Home : /home/testuser Shell : /usr/local/bin/bash Locked : no OK? (yes/no): yes adduser: INFO: Successfully added (testuser) to the user database. Add another user? (yes/no): no Goodbye! adduser: /usr/sbin/adduser /usr/share/man/man8/adduser.8.gz  | 
| 
 #!
 
 
    632         no)
    633                 _usepass="no"
    634                 ;;
    635         random)
    636                 _random="yes"
    637                 ;;
    638         esac
    639
    640         get_user
    641         get_gecos
...
    652                                 _logingroup_ok=no
    653                         fi
    654                 fi
    655         done
    656         until [ "$_groups_ok" = yes ]; do
    657                 get_groups
    658                 _groups_ok=yes
    659                 for i in $ugroups; do
    660                         if [ "$username" != "$i" ]; then
bash: syntax error near unexpected token `newline'
 | 
| 
 #ls /home/ 
[root@fbsd5:~]# ls /usr/ .snap X11R6 bin compat games include lib libdata libexec local obj ports sbin share src .snap testuser user  | 
| 
 #ls /home/testuser/ 
.cshrc .login .login_conf .mail_aliases .mailrc .profile .rhosts .shrc  | 
| 
 #ls -al /etc/skel 
[root@fbsd5:~]# ls -al /skel ls: /skel: No such file or directory total 4 drwxr-xr-x 2 root wheel 512 Oct 11 04:09 . drwxr-xr-x 21 root wheel 2048 Mar 14 09:11 ..  | 
| 
 #ls /usr/share/skel/ 
    830 uexpire=
    831 upwexpire=
    832 shells="`valid_shells`"
    833 passwdtype="yes"
    834 msgfile=/etc/adduser.msg
    835 msgflag=
    836 quietflag=
    837 configflag=
    838 fflag=
    839 infile=
...
    850 defaultgroups=
    851 defaultshell="${DEFAULTSHELL}"
    852
    853 # Make sure the user running this program is root. This isn't a security
    854 # measure as much as it is a usefull method of reminding the user to
    855 # 'su -' before he/she wastes time entering data that won't be saved.
    856 #
    857 procowner=${procowner:-`/usr/bin/id -u`}
dot.cshrc               dot.login_conf          dot.mailrc              dot.rhosts
dot.login               dot.mail_aliases        dot.profile             dot.shrc
 | 
| 
 #pw -h
 
 
[root@fbsd5:~]# pw userdel -h pw: illegal option -- h pw: unknown switch usage: pw [user|group|lock|unlock] [add|del|mod|show|next] [help|switches/values]  | 
| 
 #ls -l /home/ 
[root@fbsd5:~]# pw userdel testuser total 6 drwxrwxr-x 2 root operator 512 Feb 5 11:17 .snap drwxr-xr-x 2 1002 wheel 512 Mar 14 09:11 testuser drwxr-xr-x 14 user wheel 1024 Mar 11 15:55 user  | 
| 
 #man pw 
 | 
| 
 #pw useradd -L russian -s /usr/local/bin/bash -d /home/testuser/ -l testuser
 
 
[root@fbsd5:~]# pw useradd -L russian -s /usr/local/bin/bash -d /home/testuser/ testuser pw: user name or id required pw: illegal option -- l pw: unknown switch  | 
| 
 #vim /etc/passwd 
 | 
| 
 #vim /etc/master.passwd 
 | 
| 
 #ssh 127.0.0.1 -l testuser
 
 
      7 bin:*:3:7::0:0:Binaries Commands and Source:/:/usr/sbin/nologin
      8 tty:*:4:65533::0:0:Tty Sandbox:/:/usr/sbin/nologin
      9 kmem:*:5:65533::0:0:KMem Sandbox:/:/usr/sbin/nologin
     10 games:*:7:13::0:0:Games pseudo-user:/usr/games:/usr/sbin/nologin
     11 news:*:8:8::0:0:News Subsystem:/:/usr/sbin/nologin
     12 man:*:9:9::0:0:Mister Man Pages:/usr/share/man:/usr/sbin/nologin
     13 sshd:*:22:22::0:0:Secure Shell Daemon:/var/empty:/usr/sbin/nologin
     14 smmsp:*:25:25::0:0:Sendmail Submission User:/var/spool/clientmqueue:/usr/sbin/nologin
     15 mailnull:*:26:26::0:0:Sendmail Default User:/var/spool/mqueue:/usr/sbin/nologin
     16 bind:*:53:53::0:0:Bind Sandbox:/:/usr/sbin/nologin
...
~
~
~
~
~
"/etc/master.passwd" 31L, 2007C written
Password:
Password:
Password:
Permission denied (publickey,keyboard-interactive).
 | 
| 
 #man pwd
 
 
 | 
| 
 #pwd_mkdb -C /etc/master.passwd 
[root@fbsd5:~]# man pwd_mkdb
Formatting page, please wait...Done.
PWD_MKDB(8)             FreeBSD System Manager's Manual            PWD_MKDB(8)
NAME
     pwd_mkdb -- generate the password databases
SYNOPSIS
     pwd_mkdb [-BCiLNp] [-d directory] [-s cachesize] [-u username] file
DESCRIPTION
     The pwd_mkdb utility creates db(3) style secure and insecure databases
     for the specified file.  These databases are then installed into
...
           Specify in megabytes the size of the memory cache used by the hash-
           ing library.  On systems with a large user base, a small cache size
           can lead to prohibitively long database file rebuild times.  As a
           rough guide, the memory usage of pwd_mkdb in megabytes will be a
           little bit more than twice the figure specified here.  The default
           is 2 megabytes.
     The two databases differ in that the secure version contains the user's
     encrypted password and the insecure version has an asterisk (``*'')
     The databases are used by the C library password routines (see
     getpwent(3)).
 | 
| 
 #pwd_mkdb -u testuser /etc/master.passwd 
[root@fbsd5:~]# pwd_mkdb -u testuser usage: pwd_mkdb [-BCiLNp] [-d directory] [-s cachesize] [-u username] file  | 
| 
 #passwd testuser 
[root@fbsd5:~]# ssh 127.0.0.1 -l testuser Password: Password: Password: Permission denied (publickey,keyboard-interactive). Changing local password for testuser New Password: Retype New Password: Mismatch; try again, EOF to quit. New Password: Retype New Password:  | 
| 
 #vim /etc/master.passwd 
 | 
| 
 #grep test /etc/master.passwd 
[root@fbsd5:~]# ssh 127.0.0.1 -l testuser
Password:
Last login: Fri Mar 14 09:45:07 2008 from localhost
Copyright (c) 1980, 1983, 1986, 1988, 1990, 1991, 1993, 1994
        The Regents of the University of California.  All rights reserved.
FreeBSD 7.0-CURRENT-200710 (GENERIC) #0: Thu Oct 11 06:53:50 UTC 2007
Welcome to FreeBSD!
Before seeking technical support, please use the following resources:
o  Security advisories and updated errata information for all releases are
   at http://www.FreeBSD.org/releases/ - always consult the ERRATA section
...
unfamiliar with FreeBSD's directory layout, please refer to the hier(7)
manual page.  If you are not familiar with manual pages, type `man man'.
You may also use sysinstall(8) to re-enter the installation and
configuration utility.  Edit /etc/motd to change this login announcement.
[testuser@fbsd5 ~]$ echo $SHELL
/usr/local/bin/bash
[testuser@fbsd5 ~]$ exit
logout
Connection to 127.0.0.1 closed.
testuser:$1$4P0RJhFC$bnkKikSe22R8uwhDC04aQ.:1002:1002:russian:0:0:User &:/home/testuser/:/sbin/nologin
 | 
| 
 #ssh 127.0.0.1 -l testuser
 
 
[root@fbsd5:~]# pwd_mkdb /etc/master.passwd
Password:
Last login: Fri Mar 14 09:46:06 2008 from localhost
Copyright (c) 1980, 1983, 1986, 1988, 1990, 1991, 1993, 1994
        The Regents of the University of California.  All rights reserved.
FreeBSD 7.0-CURRENT-200710 (GENERIC) #0: Thu Oct 11 06:53:50 UTC 2007
Welcome to FreeBSD!
Before seeking technical support, please use the following resources:
o  Security advisories and updated errata information for all releases are
   at http://www.FreeBSD.org/releases/ - always consult the ERRATA section
...
   been installed, they're also available formatted in /usr/share/doc.
If you still have a question or problem, please take the output of
`uname -a', along with any relevant error messages, and email it
as a question to the questions@FreeBSD.org mailing list.  If you are
unfamiliar with FreeBSD's directory layout, please refer to the hier(7)
manual page.  If you are not familiar with manual pages, type `man man'.
You may also use sysinstall(8) to re-enter the installation and
configuration utility.  Edit /etc/motd to change this login announcement.
This account is currently not available.
Connection to 127.0.0.1 closed.
 | 
| 
 #pwd_mkdb /etc/master.passwd 
      3 root:$1$Jy.uuFuV$zHxlI.A2txIzbm8aAoa2R1:0:0::0:0:Charlie &:/root:/usr/local/bin/bash
      4 toor:$1$UusnVTvV$d4U1Eh9kP5TiSyj.hWp4Y.:0:0::0:0:Bourne-again Superuser:/root:
      5 daemon:*:1:1::0:0:Owner of many system processes:/root:/usr/sbin/nologin
      6 operator:*:2:5::0:0:System &:/:/usr/sbin/nologin
      7 bin:*:3:7::0:0:Binaries Commands and Source:/:/usr/sbin/nologin
      8 tty:*:4:65533::0:0:Tty Sandbox:/:/usr/sbin/nologin
      9 kmem:*:5:65533::0:0:KMem Sandbox:/:/usr/sbin/nologin
     10 games:*:7:13::0:0:Games pseudo-user:/usr/games:/usr/sbin/nologin
     11 news:*:8:8::0:0:News Subsystem:/:/usr/sbin/nologin
     12 man:*:9:9::0:0:Mister Man Pages:/usr/share/man:/usr/sbin/nologin
...
~
~
~
~
~
~
~
~
~
"/etc/master.passwd" 30L, 2033C written
 | 
| 
 #man pw 
 | 
| 
 #pwd_mkdb /etc/master.passwd
 
 
[root@fbsd5:~]# pw usermod testuser -s /usr/local/bin/bash  | 
| 
 #whereis passwd 
[root@fbsd5:~]# !gre grep test /etc/master.passwd testuser:$1$4P0RJhFC$bnkKikSe22R8uwhDC04aQ.:1002:1002:russian:0:0:User &:/home/testuser/:/usr/local/bin/bash passwd: /usr/bin/passwd /usr/share/man/man1/passwd.1.gz  | 
| 
 #ls -ld /tmp 
[root@fbsd5:~]# ls -l /usr/bin/passwd -r-sr-xr-x 2 root wheel 5964 Oct 11 04:13 /usr/bin/passwd drwxrwxrwt 14 root wheel 1024 Mar 14 09:47 /tmp  | 
| 
 #touch /tmp/test 
[root@fbsd5:~]# #chown testuser /  | 
| 
 #ls -l /tmp/test 
[root@fbsd5:~]# chown testuser /tmp/test total 6 -rw-r--r-- 1 root wheel 0 Mar 12 12:01 -bad-name- -rw-r--r-- 1 root wheel 0 Mar 12 11:51 A:\WINDOWS\SYSTEM32 -rw-r--r-- 1 root wheel 0 Mar 12 11:56 Queen "Live at Wembley '86" -rw-r--r-- 1 root wheel 0 Mar 12 11:48 another very long file name -rw-r--r-- 1 root wheel 0 Mar 12 13:00 cat touchlist -rw-r--r-- 1 root wheel 43 Mar 12 13:21 errlog -rw-r--r-- 1 root wheel 0 Mar 12 11:48 file wish spases at the name -rw-r--r-- 1 root wheel 1696 Mar 12 13:18 newfile -rw-r--r-- 1 root wheel 0 Mar 12 11:50 o'Reilly -rw-r--r-- 1 root wheel 0 Mar 12 11:49 one space -rw-r--r-- 1 root wheel 24 Mar 12 12:08 touchlist  | 
| 
 #find /tmp -user testuser 
[root@fbsd5:~]# ls -ld /tmp/test drwxr-xr-x 2 testuser wheel 512 Mar 14 09:53 /tmp/test /tmp/test  | 
| Время первой команды журнала | 10:13:17 2008- 3-14 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Время последней команды журнала | 11:53:30 2008- 3-14 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Количество командных строк в журнале | 101 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Процент команд с ненулевым кодом завершения, % | 32.67 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Процент синтаксически неверно набранных команд, % | 0.00 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Суммарное время работы с терминалом *, час | 1.67 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Количество командных строк в единицу времени, команда/мин | 1.01 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Частота использования команд | 
  | 
В журнал автоматически попадают все команды, данные в любом терминале системы.
Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду w. В поле WHAT, соответствующем текущему терминалу, должна быть указана программа script.
Команды, при наборе которых были допущены синтаксические ошибки, выводятся перечёркнутым текстом:
$ l s-l bash: l: command not found  | 
Если код завершения команды равен нулю, команда была выполнена без ошибок. Команды, код завершения которых отличен от нуля, выделяются цветом.
$ test 5 -lt 4  | 
Команды, ход выполнения которых был прерван пользователем, выделяются цветом.
$ find / -name abc find: /home/devi-orig/.gnome2: Keine Berechtigung find: /home/devi-orig/.gnome2_private: Keine Berechtigung find: /home/devi-orig/.nautilus/metafiles: Keine Berechtigung find: /home/devi-orig/.metacity: Keine Berechtigung find: /home/devi-orig/.inkscape: Keine Berechtigung ^C  | 
Команды, выполненные с привилегиями суперпользователя, выделяются слева красной чертой.
# id uid=0(root) gid=0(root) Gruppen=0(root)  | 
Изменения, внесённые в текстовый файл с помощью редактора, запоминаются и показываются в журнале в формате ed. Строки, начинающиеся символом "<", удалены, а строки, начинающиеся символом ">" -- добавлены.
$ vi ~/.bashrc 
  | 
Для того чтобы изменить файл в соответствии с показанными в диффшоте изменениями, можно воспользоваться командой patch. Нужно скопировать изменения, запустить программу patch, указав в качестве её аргумента файл, к которому применяются изменения, и всавить скопированный текст:
$ patch ~/.bashrc  | 
Для того чтобы получить краткую справочную информацию о команде, нужно подвести к ней мышь. Во всплывающей подсказке появится краткое описание команды.
Если справочная информация о команде есть, команда выделяется голубым фоном, например: vi. Если справочная информация отсутствует, команда выделяется розовым фоном, например: notepad.exe. Справочная информация может отсутствовать в том случае, если (1) команда введена неверно; (2) если распознавание команды LiLaLo выполнено неверно; (3) если информация о команде неизвестна LiLaLo. Последнее возможно для редких команд.
Большие, в особенности многострочные, всплывающие подсказки лучше всего показываются браузерами KDE Konqueror, Apple Safari и Microsoft Internet Explorer. В браузерах Mozilla и Firefox они отображаются не полностью, а вместо перевода строки выводится специальный символ.
Время ввода команды, показанное в журнале, соответствует времени начала ввода командной строки, которое равно тому моменту, когда на терминале появилось приглашение интерпретатора
Имя терминала, на котором была введена команда, показано в специальном блоке. Этот блок показывается только в том случае, если терминал текущей команды отличается от терминала предыдущей.
Вывод не интересующих вас в настоящий момент элементов журнала, таких как время, имя терминала и других, можно отключить. Для этого нужно воспользоваться формой управления журналом вверху страницы.
Небольшие комментарии к командам можно вставлять прямо из командной строки. Комментарий вводится прямо в командную строку, после символов #^ или #v. Символы ^ и v показывают направление выбора команды, к которой относится комментарий: ^ - к предыдущей, v - к следующей. Например, если в командной строке было введено:
$ whoami
user
$ #^ Интересно, кто я?в журнале это будет выглядеть так:
$ whoami
user
|  Интересно, кто я? | 
Если комментарий содержит несколько строк, его можно вставить в журнал следующим образом:
$ whoami
user
$ cat > /dev/null #^ Интересно, кто я?
Программа whoami выводит имя пользователя, под которым мы зарегистрировались в системе. - Она не может ответить на вопрос о нашем назначении в этом мире.В журнале это будет выглядеть так:
$ whoami user 
  | 
Комментарии, не относящиеся непосредственно ни к какой из команд, добавляются точно таким же способом, только вместо симолов #^ или #v нужно использовать символы #=
1
    2
3   
    4
    Группы команд, выполненных на разных терминалах, разделяются специальной линией.
    Под этой линией в правом углу показано имя терминала, на котором выполнялись команды.
    Для того чтобы посмотреть команды только одного сенса, 
    нужно щёкнуть по этому названию.
    
    LiLaLo (L3) расшифровывается как Live Lab Log.
    Программа разработана для повышения эффективности обучения Unix/Linux-системам.
    (c) Игорь Чубин, 2004-2008