⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 3.t

📁 早期freebsd实现
💻 T
📖 第 1 页 / 共 5 页
字号:
and read the manual pages for the commands contained in itbefore trying to merge your local copy.Note in particular that.Xr ifconfighas had many changes,and that host names are now fully specified as domain-style names(e.g., vangogh.CS.Berkeley.EDU) for the benefit of the name server..PPSome of the commands previously in.Pn /etc/dailyhave been moved to.Pn /etc/security ,and several new functions have been added to.Pn /etc/securityto do nightly security checks on the system.The script.Pn /etc/dailyruns.Pn /etc/securityeach night, and mails the output to the super-user.Some of the checks done by.Pn /etc/securityare:.DS\(bu Syntax errors in the password and group files.\(bu Duplicate user and group names and id's.\(bu Dangerous search paths and umask values for the superuser.\(bu Dangerous values in various initialization files.\(bu Dangerous .rhosts files.\(bu Dangerous directory and file ownership or permissions.\(bu Globally exported filesystems.\(bu Dangerous owners or permissions for special devices..DEIn addition, it reports any changes to setuid and setgid files, specialdevices, or the files in.Pn /etc/changelistsince the last run of.Pn /etc/security .Backup copies of the files are saved in.Pn /var/backups .Finally, the system binaries are checksummed and their permissionsvalidated against the.Xr mtree (8)specifications in.Pn /etc/mtree ..PPThe C-library and system binaries on the distribution tapeare compiled with new versions of.Xr gethostbynameand.Xr gethostbyaddrthat use the name server,.Xr named (8).If you have only a small network and are not connectedto a large network, you can use the distributed library routines withoutany problems; they use a linear scan of the host table.Pn /etc/hostsif the name server is not running.If you are on the Internet or have a large local network,it is recommend that you set upand use the name server.For instructions on how to set up the necessary configuration files,refer to ``Name Server Operations Guide for BIND'' (SMM:10).Several programs rely on the host name returned by.Xr gethostnameto determine the local domain name..PPIf you are using the name server, your.Xr sendmailconfiguration file will need some updates to accommodate it.See the ``Sendmail Installation and Operation Guide'' (SMM:8) andthe sample.Xr sendmailconfiguration files in.Pn /usr/src/usr.sbin/sendmail/cf .The aliases file,.Pn /etc/aliaseshas also been changed to add certain well-known addresses..Sh 3 "Shadow password files".PPThe password file format adds change and expiration fieldsand its location has changed to protectthe encrypted passwords stored there.The actual password file is now stored in.Pn /etc/master.passwd .The hashed dbm password files do not contain encrypted passwords,but contain the file offset to the entry with the password in.Pn /etc/master.passwd(that is readable only by root).Thus, the.Fn getpwnamand.Fn getpwuidfunctions will no longer return an encrypted password string to non-rootcallers.An old-style passwd file is created in.Pn /etc/passwdby the.Xr vipw (8)and.Xr pwd_mkdb (8)programs.See also.Xr passwd (5)..PPSeveral new users have also been added to the group of ``well-known'' users in.Pn /etc/passwd .The current list is:.DS.TSl c.name	number_root	0daemon	1operator	2bin	3games	7uucp	66nobody	32767.TE.DEThe ``daemon'' user is used for daemon processes thatdo not need root privileges.The ``operator'' user-id is used as an account for dumpersso that they can log in without having the root password.By placing them in the ``operator'' group, they can get read access to the disks.The ``uucp'' login has existed long before \*(4B,and is noted here just to provide a common user-id.The password entry ``nobody'' has been added to specifythe user with least privilege.  The ``games'' user is a pseudo-userthat controls access to game programs..PPAfter installing your updated password file, you must run.Xr pwd_mkdb (8)to create the password database.Note that.Xr pwd_mkdb (8)is run whenever.Xr vipw (8)is run..Sh 3 "The \f(CW/var\fP filesystem".PPThe spooling directories saved on tape may be restored in theireventual resting places without too much concern.  Be sure touse the `\-p' option to.Xr tar (1)so that files are recreated with the same file modes.The following commands provide a guide for copying spool and log files froman existing system into a new.Pn /varfilesystem.At least the following directories should already exist on.Pn /var :.Pn output ,.Pn log ,.Pn backupsand.Pn db ..LP.DS.ft CWSRC=/oldroot/usrcd $SRC; tar cf - msgs preserve | (cd /var && tar xpf -).DE.DS.ft CW# copy $SRC/spool to /varcd $SRC/spooltar cf - at mail rwho | (cd /var && tar xpf -)tar cf - ftp mqueue news secretmail uucp uucppublic | \e	(cd /var/spool && tar xpf -).DE.DS.ft CW# everything else in spool is probably a printer areamkdir .savemv at ftp mail mqueue rwho secretmail uucp uucppublic .savetar cf - * | (cd /var/spool/output && tar xpf -)mv .save/* .rmdir .save.DE.DS.ft CWcd /var/spool/mqueuemv syslog.7 /var/log/maillog.7mv syslog.6 /var/log/maillog.6mv syslog.5 /var/log/maillog.5mv syslog.4 /var/log/maillog.4mv syslog.3 /var/log/maillog.3mv syslog.2 /var/log/maillog.2mv syslog.1 /var/log/maillog.1mv syslog.0 /var/log/maillog.0mv syslog /var/log/maillog.DE.DS.ft CW# move $SRC/adm to /varcd $SRC/admtar cf - . | (cd /var/account && tar  xpf -)cd /var/accountrm -f msgbufmv messages messages.[0-9] ../logmv wtmp wtmp.[0-9] ../logmv lastlog ../log.DE.Sh 2 "Bug fixes and changes between \*(Ps and \*(4B".PPThe major new facilities available in the \*(4B release area new virtual memory system,the addition of ISO/OSI networking support,a new virtual filesystem interface supporting filesystem stacking,a freely redistributable implementation of NFS,a log-structured filesystem,enhancement of the local filesystems to supportfiles and filesystems that are up to 2^63 bytes in size,enhanced security and system management support,and the conversion to and addition of the IEEE Std1003.1 (``POSIX'')facilities and many of the IEEE Std1003.2 facilities.In addition, many new utilities and additions to the Clibrary are present as well.The kernel sources have been reorganized to collect all machine-dependentfiles for each architecture under one directory,and most of the machine-independent code is now free of codeconditional on specific machines.The user structure and process structure have been reorganizedto eliminate the statically-mapped user structure and to make mostof the process resources shareable by multiple processes.The system and include files have been converted to be compatiblewith ANSI C, including function prototypes for most of the exportedfunctions.There are numerous other changes throughout the system..Sh 3 "Changes to the kernel".PPThis release includes several important structural kernel changes.The kernel uses a new internal system call convention;the use of global (``u-dot'') variables for parameters and error returnshas been eliminated,and interrupted system calls no longer abort using non-local goto's (longjmp's).A new sleep interface separates signal handling from scheduling priority,returning characteristic errors to abort or restart the current system call.This sleep call also passes a string describing the process state,that is used by the ps(1) program.The old sleep interface can be used only for non-interruptible sleeps.The sleep interface (\fItsleep\fP) can be used at any priority,but is only interruptible if the PCATCH flag is set.When interrupted, \fItsleep\fP returns EINTR or ERESTART..PPMany data structures that were previously statically allocatedare now allocated dynamically.These structures include mount entries, file entries,user open file descriptors, the process entries, the vnode table,the name cache, and the quota structures..PPTo protect against indiscriminate reading or writing of kernelmemory, all writing and most reading of kernel data structuresmust be done using a new ``sysctl'' interface.The information to be accessed is described through an extensible``Management Information Base'' (MIB) style name,described as a dotted set of components.A new utility,.Xr sysctl (8),retrieves kernel state and allows processes with appropriateprivilege to set kernel state..Sh 3 "Security".PPThe kernel runs with four different levels of security.Any superuser process can raise the security level, but only .Fn init (8)can lower it.Security levels are defined as follows:.IP \-1Permanently insecure mode \- always run system in level 0 mode..IP "  0"Insecure mode \- immutable and append-only flags may be turned off.All devices may be read or written subject to their permissions..IP "  1"Secure mode \- immutable and append-only flags may not be cleared;disks for mounted filesystems,.Pn /dev/mem ,and.Pn /dev/kmemare read-only..IP "  2"Highly secure mode \- same as secure mode, plus disks are alwaysread-only whether mounted or not.This level precludes tampering with filesystems by unmounting them,but also inhibits running.Xr newfs (8)while the system is multi-user.See.Xr chflags (1)and the \-\fBo\fP option to .Xr ls (1)for information on setting and displaying the immutable and append-onlyflags..PPNormally, the system runs in level 0 mode while single userand in level 1 mode while multiuser.If the level 2 mode is desired while running multiuser,it can be set in the startup script.Pn /etc/rcusing.Xr sysctl (1).If it is desired to run the system in level 0 mode while multiuser,the administrator must build a kernel with the variable.Li securelevelin the kernel source file.Pn /sys/kern/kern_sysctl.cinitialized to \-1..Sh 4 "Virtual memory changes".PPThe new virtual memory implementation is derived from the Machoperating system developed at Carnegie-Mellon,and was ported to the BSD kernel at the University of Utah.It is based on the 2.0 release of Mach(with some bug fixes from the 2.5 and 3.0 releases)and retains many of its essential features such asthe separation of the machine dependent and independent layers(the ``pmap'' interface),efficient memory utilization using copy-on-writeand other lazy-evaluation techniques,and support for large, sparse address spaces.It does not include the ``external pager'' interface instead usinga primitive internal pager interface.The Mach virtual memory system call interface has been replaced with the``mmap''-based interface described in the ``Berkeley SoftwareArchitecture Manual'' (see UNIX Programmer's Manual,Supplementary Documents, PSD:5).The interface is similar to the interfaces shippedby several commercial vendors such as Sun, USL, and Convex Computer Corp.The integration of the new virtual memory is functionally complete,but still has serious performance problems under heavy memory load.The internal kernel interfaces have not yet been completedand the memory pool and buffer cache have not been merged.Some additional caveats:.IP \(buSince the code is based on the 2.0 release of Mach,bugs and misfeatures of the BSD version should not be consideredshort-comings of the current Mach virtual memory system..IP \(buBecause of the disjoint virtual memory (page) and IO (buffer) caches,it is possible to see inconsistencies if using both the mmap andread/write interfaces on the same file simultaneously..IP \(buSwap space is allocated on-demand rather than up front and noallocation checks are performed so it is possible to over-commitmemory and eventually deadlock..IP \(buThe semantics of the.Xr vfork (2)system call are slightly different.The synchronization between parent and child is preserved,but the memory sharing aspect is not.In practice this has been enough for backward compatibility,but newer code should just use.Xr fork (2)..Sh 4 "Networking additions and changes".PPThe ISO/OSI Networking consists of a kernel implementation oftransport class 4 (TP-4),connectionless networking protocol (CLNP),and 802.3-based link-level support (hardware-compatible with Ethernet\**)..FSEthernet is a trademark of the Xerox Corporation.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -