/l3/users/abear/nt-bsdnet/fbsd3.unix.nt/root :1 :2 :3 :4 :5 :6 :7 :8 :9 :10 :11 :12 :13 :14 :15 :16 :17 :18 :19 :20 :21 :22 :23 :24 :25 :26 :27 :28 :29 :30 :31 |
|
#pppd 192.168.19.254:192.168.19.1
![]() # and a USER_PROCESS utmp entry with ut_user = "utmp_entry" # pppd: local/remote LL address required for demand-dialling # # userid is a valid user name from /etc/passwd, or "-" to not set # a login user id and keep the uid/euid root (needed for /bin/login) # # utmp_entry is what will appear in the "who" listing. Use "-" to not # set an utmp entry (a must for /bin/login), use "@" to set it to the # username entered. Maximum length is 8 characters. ... # username entered. Warning: if no "@" is given, the login_program has # no way to know what user name the user entered. # # SAMPLES: # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. # (Big advantage: tuucp can use the same passwd file for serial dial-in # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. # #U* uucp @ /usr/lib/uucp/uucico -l -u @ # |
#man pppd
|
#vi /etc/ppp/options
|
#pppd 192.168.19.254:192.168.19.1
![]() pppd: local/remote LL address required for demand-dialling |
#vi /etc/ppp/options
|
#vi /etc/ppp/options
|
#man pppd
|
#~q
![]() bash: ~q: command not found |
#cd /etc/ppp/
|
#ls -l
total 8 -rw-r--r-- 1 root wheel 33 Dec 1 16:01 chat -rw-r--r-- 1 root wheel 182 Dec 1 16:10 options -rw------- 1 root wheel 18 Dec 1 15:49 pap-secrets -rw------- 1 root wheel 1167 Nov 3 2005 ppp.conf |
#cp options options.cuad0
|
#vi options.cuad0
|
#vi options.cuad0
|
#pppd 192.168.19.254:192.168.19.1
![]() pppd: local/remote LL address required for demand-dialling |
#pppd
![]() pppd: local/remote LL address required for demand-dialling |
#pppd
![]() pppd: local/remote LL address required for demand-dialling |
#vi options
|
#pppd
|
#ifconfig
# # SAMPLEinet 192.168.15.21 netmask 0xffffff00 broadcast 192.168.15.255 # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. # (Big inet 10.0.0.21 netmask 0xffffff00 broadcast 10.0.0.255al dial-in # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. # ether 00:04:76:a1:f2:5b #U* uucp @ /usr/lib/uucp/uucico -l -u @ media: Ethernet autoselect (100baseTX <full-duplex>) # status: active plip0: flags=108810<POINTOPOINT,SIMPLEX,MULTICAST,NEEDSGIANT> mtu 1500 lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384 inet6 ::1 prefixlen 128 inet 127.0.0.1 netmask 0xff000000 ppp0: flags=108051<UP,POINTOPOINT,RUNNING,MULTICAST,NEEDSGIANT> mtu 1500 inet 192.168.19.254 --> 192.168.19.1 netmask 0xffffff00 |
#cat options
192.168.19.254:192.168.19.1 defaultroute 38400 /dev/cuad0 lock debug noauth user user connect '/usr/bin/chat -f /etc/ppp/chat' idle 60 ipcp-accept-remote ipcp-accept-local |
#pkill pppd
|
#less options
|
#vi options
|
#vi options
|
#pppd
![]() pppd: local/remote LL address required for demand-dialling |
#cd /usr/ports/
# and a USER_PROCESS utmp entry with ut_user = "utmp_entry" # # username may be prefixed / suffixed by "*" (wildcard) # # userid is a valid user name from /etc/passwd, or "-" to not set # a login user id and keep the uid/euid root (needed for /bin/login) # # utmp_entry is what will appear in the "who" listing. Use "-" to not # set an utmp entry (a must for /bin/login), use "@" to set it to the # username entered. Maximum length is 8 characters. ... # username entered. Warning: if no "@" is given, the login_program has # no way to know what user name the user entered. # # SAMPLES: # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. # (Big advantage: tuucp can use the same passwd file for serial dial-in # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. # #U* uucp @ /usr/lib/uucp/uucico -l -u @ # |
#make search name=mpd
Port: libmpd-0.12.0 Path: /usr/ports/audio/libmpd Info: Abstraction around libmpdclient Maint: redchrom@gmail.com B-deps: R-deps: WWW: http://cms.qballcow.nl/index.php?page=libmpd Port: mpdcon-1.1.99 Path: /usr/ports/audio/mpdcon Info: A GNUstep MPD client ... B-deps: autoconf-2.59_2 gettext-0.14.5_2 gmake-3.81_1 libbegemot-1.11 libiconv-1.9.2_2 libltdl-1.5.22 libsmi-0.4.5 m4-1.4.4 perl-5.8.8 pkg-config-0.21 R-deps: libbegemot-1.11 libltdl-1.5.22 libsmi-0.4.5 pkg-config-0.21 WWW: http://people.freebsd.org/~harti/bsnmp/ Port: isakmpd-20041207_2 Path: /usr/ports/security/isakmpd Info: OpenBSD IKE daemon Maint: simon@FreeBSD.org B-deps: R-deps: WWW: http://www.openbsd.org/ |
#make search name=mpd | less
|
#cd net/mpd
|
#make install
these network services to be started at boot time. /usr/local/etc/rc.d/mpd.sh If there are vulnerabilities in these programs there may be a security risk to the system. FreeBSD makes no guarantee about the security of ports included in the Ports Collection. Please type 'make deinstall' to deinstall the port if this is a concern. For more information, and contact details about the security status of this software, see the following webpage: http://sourceforge.net/projects/mpd/ |
#vi /etc/rc.conf
|
#cd /usr/local/etc/rc.d/
|
#ls
000.compat4x.sh genkdmconf.sh rsyncd.sh 000.compat5x.sh kdelibs.sh sa-spamd.sh 000.mysql-client.sh mailgraph.sh samba.sh.sample 001slpd.sh mdnsd.sh snmpd.sh apache.sh mdnsresponder.sh snmptrapd.sh clamav-clamd.sh mimedefang.sh squid.sh clamav-freshclam.sh mimedefang.sh-dist xinetd.sh cups.sh.sample mpd.sh |
#cd ..
|
#ls
Muttrc freshclam.conf rc.d Muttrc.dist freshclam.conf.default rsyncd.conf a2ps-site.cfg ksysguarddrc rsyncd.conf.sample a2ps.cfg mail smb.conf.default apache mime.types snmp bonobo-activation mimedefang squid cdrecord minicom sudoers cdrecord.sample mpd sudoers.sample clamd.conf mtools.conf trafshow clamd.conf.default mtools.conf.sample trafshow.dist codepages openldap wgetrc cups openslp xdg esd.conf orbit2rc xinetd.conf esd.conf.default orbit2rc.default xml2Conf.sh etter.conf pam.d xsltConf.sh etter.conf.sample qpopper fam.conf qpopper.config.sample |
#cd mpd
|
#ls
![]() mpd.conf.sample mpd.script.sample mpd.links.sample mpd.secret.sample |
#pwd
/usr/local/etc/mpd |
#hosntma
![]() # and a USER_PROCESS utmp entry with ut_user = "utmp_entry" # bash: hosntma: command not foundfixed by "*" (wildcard) # # userid is a valid user name from /etc/passwd, or "-" to not set # a login user id and keep the uid/euid root (needed for /bin/login) # # utmp_entry is what will appear in the "who" listing. Use "-" to not # set an utmp entry (a must for /bin/login), use "@" to set it to the # username entered. Maximum length is 8 characters. ... # username entered. Warning: if no "@" is given, the login_program has # no way to know what user name the user entered. # # SAMPLES: # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. # (Big advantage: tuucp can use the same passwd file for serial dial-in # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. # #U* uucp @ /usr/lib/uucp/uucico -l -u @ # |
#hostname
ns.sergey.unix.nt |
#ls
mpd.conf.sample mpd.script.sample mpd.links.sample mpd.secret.sample |
#a=mpd.conf.sample
# and a USER_PROCESS utmp entry with ut_user = "utmp_entry" # # username may be prefixed / suffixed by "*" (wildcard) # # userid is a valid user name from /etc/passwd, or "-" to not set # a login user id and keep the uid/euid root (needed for /bin/login) # # utmp_entry is what will appear in the "who" listing. Use "-" to not # set an utmp entry (a must for /bin/login), use "@" to set it to the # username entered. Maximum length is 8 characters. ... # username entered. Warning: if no "@" is given, the login_program has # no way to know what user name the user entered. # # SAMPLES: # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. # (Big advantage: tuucp can use the same passwd file for serial dial-in # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. # #U* uucp @ /usr/lib/uucp/uucico -l -u @ # |
#echo ${a##.sample}
mpd.conf.sample |
#echo ${a%%.sample}
mpd.conf |
#for i in *sample
# and a USER_PROCESS utmp entry with ut_user = "utmp_entry" # > doername may be prefixed / suffixed by "*" (wildcard) # > cp $i ${i%%.sample} er name from /etc/passwd, or "-" to not set # a login user id and keep the uid/euid root (needed for /bin/login) > done # utmp_entry is what will appear in the "who" listing. Use "-" to not # set an utmp entry (a must for /bin/login), use "@" to set it to the # username entered. Maximum length is 8 characters. ... # username entered. Warning: if no "@" is given, the login_program has # no way to know what user name the user entered. # # SAMPLES: # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. # (Big advantage: tuucp can use the same passwd file for serial dial-in # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. # #U* uucp @ /usr/lib/uucp/uucico -l -u @ # |
#ls
mpd.conf mpd.links.sample mpd.secret mpd.conf.sample mpd.script mpd.secret.sample mpd.links mpd.script.sample |
#ls -l
total 116 -r--r--r-- 1 root wheel 10401 Dec 1 16:41 mpd.conf -r--r--r-- 1 root wheel 10401 Dec 1 16:15 mpd.conf.sample -r--r--r-- 1 root wheel 3734 Dec 1 16:41 mpd.links -r--r--r-- 1 root wheel 3734 Dec 1 16:15 mpd.links.sample -r--r--r-- 1 root wheel 39085 Dec 1 16:41 mpd.script -r--r--r-- 1 root wheel 39085 Dec 1 16:15 mpd.script.sample -r--r--r-- 1 root wheel 868 Dec 1 16:41 mpd.secret -r--r--r-- 1 root wheel 868 Dec 1 16:15 mpd.secret.sample |
#vi mpd.conf
|
#[root@ns:mpd]# ls
mpd.conf mpd.links.sample mpd.secret mpd.conf.sample mpd.script mpd.secret.sample mpd.links mpd.script.sample |
#vi mpd.links
|
#vi mpd.links
|
#ls
mpd.conf mpd.links.sample mpd.secret mpd.conf.sample mpd.script mpd.secret.sample mpd.links mpd.script.sample |
#vi mpd.secret
|
#vi mpd.secret
|
#vi mpd.secret
|
#vi mpd.secret
|
#chmod 600 mpd.secret
|
#cat mpd.secret
################################################################# # # MPD secrets file # # This file contains login, password pairs, called "secrets". # Entries are used for authentication in either or both directions, # as well as telnet console login. # # For example, to use the "MyLogin" secret, use this command: # ... # ################################################################# user password MyLogin MyPassword PeerLogin PeerPassword ConsoleLogin ConsolePassword fred "fred-pw" joe "foobar" 192.168.1.1 bob "\x34\"foo\n" 192.168.1.10/24 sal "yipee" 192.168.1.254 |
#/usr/local/etc/rc.d/mpd.sh start
# and a USER_PROCESS utmp entry with ut_user = "utmp_entry" # Starting mpd.y be prefixed / suffixed by "*" (wildcard) # # userid is a valid user name from /etc/passwd, or "-" to not set # a login user id and keep the uid/euid root (needed for /bin/login) # # utmp_entry is what will appear in the "who" listing. Use "-" to not # set an utmp entry (a must for /bin/login), use "@" to set it to the # username entered. Maximum length is 8 characters. ... # username entered. Warning: if no "@" is given, the login_program has # no way to know what user name the user entered. # # SAMPLES: # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. # (Big advantage: tuucp can use the same passwd file for serial dial-in # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. # #U* uucp @ /usr/lib/uucp/uucico -l -u @ # |
#tail /var/log/messages
# and a USER_PROCESS utmp entry with ut_user = "utmp_entry" # Dec 1 16:11:44 ns pppd[59518]: local/remote LL address required for demand-dialling # Dec 1 16:11:46 ns pppd[59524]: local/remote LL address required for demand-dialling # a login user id and keep the uid/euid root (needed for /bin/login) Dec 1 16:11:46 ns pppd[59530]: local/remote LL address required for demand-dialling # utmp_entry is what will appear in the "who" listing. Use "-" to not Dec 1 16:11:56 ns pppd[59551]: pppd 2.3.5 started by root, uid 0o the # username entered. Maximum length is 8 characters. ... # username entered. Warning: if no "@" is given, the login_program has Dec 1 16:12:21 ns pppd[59551]: local IP address 192.168.19.254 # Dec 1 16:12:21 ns pppd[59551]: remote IP address 192.168.19.1 # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. Dec 1 16:13:18 ns pppd[59551]: Connection terminated, connected for 1 minutes # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. Dec 1 16:13:50 ns pppd[59626]: local/remote LL address required for demand-dialling #U* uucp @ /usr/lib/uucp/uucico -l -u @ # |
#sysctl -a | grep forw
net.inet.ip.forwarding: 0 net.inet.ip.fastforwarding: 0 net.inet6.ip6.forwarding: 0 |
#sysctl net.inet.ip.forwarding=1
net.inet.ip.forwarding: 0 -> 1 |
#sysctl net.inet.ip.forwarding=1
# and a USER_PROCESS utmp entry with ut_user = "utmp_entry" # net.inet.ip.forwarding: 1 -> 1uffixed by "*" (wildcard) # # userid is a valid user name from /etc/passwd, or "-" to not set # a login user id and keep the uid/euid root (needed for /bin/login) # # utmp_entry is what will appear in the "who" listing. Use "-" to not # set an utmp entry (a must for /bin/login), use "@" to set it to the # username entered. Maximum length is 8 characters. ... # username entered. Warning: if no "@" is given, the login_program has # no way to know what user name the user entered. # # SAMPLES: # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. # (Big advantage: tuucp can use the same passwd file for serial dial-in # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. # #U* uucp @ /usr/lib/uucp/uucico -l -u @ # |
#cat mpd.
![]() mpd.conf mpd.links mpd.script mpd.secret mpd.conf.sample mpd.links.sample mpd.script.sample mpd.secret.sample |
#cat mpd.conf
set iface idle 1800 set iface enable tcpmssfix set bundle enable multilink # enable TCP-Wrapper (hosts_access(5)) to block unfriendly clients # set bundle enable tcp-wrapper # use RADIUS servers # load radius set link yes acfcomp protocomp set link no pap chap set link enable chap ... set bundle authname "<change_this>" set bundle password "<change_this>" set link yes acfcomp protocomp set link no pap chap set link accept chap set link mtu 1460 set link keep-alive 10 75 set ipcp yes vjcomp set ipcp ranges 0/0 10.0.0.138/0 open |
#cat mpd.
![]() # and a USER_PROCESS utmp entry with ut_user = "utmp_entry" # mpd.conf mpd.links mpd.script mpd.secret # mpd.conf.sample mpd.links.sample mpd.script.sample mpd.secret.sample # a login user id and keep the uid/euid root (needed for /bin/login) # # utmp_entry is what will appear in the "who" listing. Use "-" to not # set an utmp entry (a must for /bin/login), use "@" to set it to the # username entered. Maximum length is 8 characters. ... # username entered. Warning: if no "@" is given, the login_program has # no way to know what user name the user entered. # # SAMPLES: # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. # (Big advantage: tuucp can use the same passwd file for serial dial-in # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. # #U* uucp @ /usr/lib/uucp/uucico -l -u @ # |
#cat mpd.links
pptp: set link type pptp set pptp self 192.168.15.21 set pptp enable incoming set pptp disable originate |
#cat mpd.script
![]() ## ModemCmd2: call ModemCmd if $modemCmdResult == "OK" return log $ErrorMsg failure ## ## ModemCmdSend ## ## Send a modem command and read the echo'ed CR-LF ... # the peer, otherwise we'll just timeout. match "ogin" AutoLoginPrompt match "name" AutoLoginPrompt wait 1 print "\r" match "ogin" AutoLoginPrompt match "name" AutoLoginPrompt wait # At this point we'veConnection to 192.168.15.21 closed by remote host. Connection to 192.168.15.21 closed. |
# and a USER_PROCESS utmp entry with ut_user = "utmp_entry" # mpd.conf mpd.links mpd.script mpd.secret # mpd.conf.sample mpd.links.sample mpd.script.sample mpd.secret.sample # a login user id and keep the uid/euid root (needed for /bin/login) # # utmp_entry is what will appear in the "who" listing. Use "-" to not # set an utmp entry (a must for /bin/login), use "@" to set it to the # username entered. Maximum length is 8 characters. # # login_program is the program that will be exec()ed, with the arguments # passed in [arguments]. A "@" in the arguments will be replaced with the # username entered. Warning: if no "@" is given, the login_program has # no way to know what user name the user entered. # # SAMPLES: # Use this one with my Taylor-UUCP and Taylor-UUCP passwd files. # (Big advantage: tuucp can use the same passwd file for serial dial-in # and tcp dial-in [uucico running as in.uucpd]). Works from 1.05 up. # #U* uucp @ /usr/lib/uucp/uucico -l -u @ #
set iface idle 1800 set iface enable tcpmssfix set bundle enable multilink # enable TCP-Wrapper (hosts_access(5)) to block unfriendly clients # set bundle enable tcp-wrapper # use RADIUS servers # load radius set link yes acfcomp protocomp set link no pap chap set link enable chap set link keep-alive 10 60 set link mtu 1460 set ipcp yes vjcomp set ipcp ranges 192.168.15.101/32 192.168.15.150/32 set ipcp dns 192.168.15.254 set ipcp nbns 192.168.1.4 # # The five lines below enable Microsoft Point-to-Point encryption # (MPPE) using the ng_mppc(8) netgraph node type. # set bundle enable compression set ccp yes mppc set ccp yes mpp-e40 set ccp yes mpp-e128 set ccp yes mpp-stateless # # Mpd using PPTP for LAN to LAN VPN, always connected. # # Suppose you have a private Office LAN numbered 192.168.1.0/24 and another # remote private Office LAN numbered 192.168.2.0/24, and you wanted to route # between these two private networks using a PPTP VPN over the Internet. # # You run mpd on dual-homed machines on either end. Say the local machine # has internal address 192.168.1.1 and externally visible address 1.2.3.4, # and the remote machine has internal address 192.168.2.1 and externally # visible address 2.3.4.5. # # Note: mpd does not support the peer's "inside" IP address being the same # as its "outside" IP address. In the above example, this means that # 192.168.2.1 != 2.3.4.5. # # The "inside" IP addresses are configured by "set ipcp ranges ..." # (in mpd.conf) while the "outside" IP addreses are configured by # "set pptp self ..." and "set pptp peer ..." (in mpd.links). # # See also the 'vpn' link entry in mpd.links.sample. # vpn: new -i ng1 vpn vpn set iface disable on-demand set iface addrs 192.168.1.1 192.168.2.1 set iface idle 0 # disconnect the client after 8 hours set iface session 28800 set iface route 192.168.2.0/24 set bundle disable multilink set bundle authname "VpnLogin" set bundle password "VpnPassword" set link yes acfcomp protocomp set link no pap set link yes chap set link mtu 1460 # If remote machine is NT you need this.. # set link enable no-orig-auth set link keep-alive 10 75 set ipcp yes vjcomp set ipcp ranges 192.168.1.1/32 192.168.2.1/32 # # The five lines below enable Microsoft Point-to-Point encryption # (MPPE) using the ng_mppc(8) netgraph node type. # set bundle enable compression set ccp yes mppc set ccp yes mpp-e40 set ccp yes mpp-e128 set bundle enable crypt-reqd set ccp yes mpp-stateless open # # PPPoE client example (see also mpd.links.sample entry "PPPoE") # PPPoE: new -i ng0 PPPoE PPPoE set iface addrs 1.1.1.1 2.2.2.2 set iface route default set iface disable on-demand set iface idle 0 set bundle disable multilink set bundle authname MyLogin set link no acfcomp protocomp set link disable pap chap set link accept chap set link mtu 1492 set link keep-alive 10 60 set ipcp yes vjcomp set ipcp ranges 0.0.0.0/0 0.0.0.0/0 open iface radius: # You can use radius.conf(5), its useful, because you can share the # same config with userland-ppp and other apps. set radius config /etc/radius.conf # and/or specify the server directly here set radius retries 3 set radius timeout 3 set radius server localhost testing123 1812 1813 # send the given IP in the RAD_NAS_IP_ADDRESS attribute to the server. set radius me 1.1.1.1 # send accounting updates every 5 minutes set radius acct-update 300 # let the RADIUS server assign the IP set ipcp enable radius-ip # enable RADIUS, and fallback to mpd.secret, if RADIUS auth failed set bundle enable radius-auth radius-fallback # enable RADIUS accounting set bundle enable radius-acct # use idle-timeout, session-timeout, routes list and mtu from the RADIUS server set iface enable radius-idle radius-session radius-mtu radius-route # activate MPPE and let the RADIUS server assign MPPE-types and MPPE-policies set bundle enable compression set ccp yes mppc set ccp enable radius # # Country specific configuration examples # # Austria ADSL adslat: new -i ng0 adslat adslat set iface disable on-demand set iface idle 0 set iface session 0 set iface route default set bundle disable multilink set bundle authname "<change_this>" set bundle password "<change_this>" set link yes acfcomp protocomp set link no pap chap set link accept chap set link mtu 1460 set link keep-alive 10 75 set ipcp yes vjcomp set ipcp ranges 0/0 10.0.0.138/0 open
pptp: set link type pptp set pptp self 192.168.15.21 set pptp enable incoming set pptp disable originate
################################################################# # # MPD secrets file # # This file contains login, password pairs, called "secrets". # Entries are used for authentication in either or both directions, # as well as telnet console login. # # For example, to use the "MyLogin" secret, use this command: # # set bundle authname MyLogin # # Each entry may have a third field containing an IP address range # specifying the allowable address assignments for that # peer. # # NOTE: this file should not be readable by anyone except root! # # $Id: mpd.secret.sample,v 1.1 2001/03/10 06:06:47 archiecobbs Exp $ # ################################################################# user password MyLogin MyPassword PeerLogin PeerPassword ConsoleLogin ConsolePassword fred "fred-pw" joe "foobar" 192.168.1.1 bob "\x34\"foo\n" 192.168.1.10/24 sal "yipee" 192.168.1.254
192.168.19.254:192.168.19.1 defaultroute 38400 /dev/cuad0 lock debug noauth user user connect '/usr/bin/chat -f /etc/ppp/chat' idle 60 ipcp-accept-remote ipcp-accept-local
Время первой команды журнала | 18:08:48 2006-12- 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Время последней команды журнала | 19:14:05 2006-12- 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в журнале | 68 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент команд с ненулевым кодом завершения, % | 10.29 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Процент синтаксически неверно набранных команд, % | 2.94 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Суммарное время работы с терминалом *, час | 1.09 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Количество командных строк в единицу времени, команда/мин | 1.04 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Частота использования команд |
|
В журнал автоматически попадают все команды, данные в любом терминале системы.
Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду 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