To view ACLs on a file: > getfacl file.txt To modify the ACL on a file: > setfacl -m user:rwx file.txt To recursively change an ACL: > setfacl -R -m user:rwx . To modify the default ACL for a directory: > setfacl -d -m user:rwx. See the getfacl and setfacl man pages for more information.
The crle command on Solaris is used to configure the runtime linking environment (get it?). If you are seeing errors similar to the following, you may need to look at and adjust your linking environment with crle: ld.so.1: conftest: fatal: libreadline.so.5: open failed: No such file or directory Using crle is straightforward; to view the [...]
Check the status of a service: > svcs ntp STATE STIME FMRI disabled Feb_27 svc:/network/ntp:default View a service’s dependencies: > svcs -d ntp STATE STIME FMRI online Feb_27 svc:/network/service:default To see what other services depend on a given service: > svcs -D ntp STATE STIME FMRI online Feb_27 svc:/milestone/multi-user:default To enable a service: > pfexec [...]
Use zonecfg to configure the lofs mount; this will work nicely for CDs in addition to ordinary filesystems: # zonecfg -z zone1 zonecfg:zone1> add fs zonecfg:zone1:fs> set dir=/depot zonecfg:zone1:fs> set special=/depot zonecfg:zone1:fs> set type=lofs zonecfg:zone1:fs> add options [nodevices] zonecfg:zone1:fs> end zonecfg:zone1> commit zonecfg:zone1> exit special is the directory from the global zone to mount; dir is the [...]
This information, of course exists many other places on the web, but for me, most conveniently, here. An example configuration session: # zonecfg -z host1 host1: No such zone configured Use ‘create’ to begin configuring a new zone. zonecfg:host1> create zonecfg:host1> set zonepath=/zones/host1 zonecfg:host1> set autoboot=true zonecfg:host1> add net zonecfg:host1:net> set address=172.16.3.242 zonecfg:host1:net> set [...]
To display Ubuntu boot messages one time, do the following: Press “e” while the GRUB screen to select a kernel version is displayed. Edit the kernel line, again by pressing “e”, to remove any references to “quiet” – it is generally at the end of the line, with “splash”. Edit the fifth line, below the [...]
The Exim port on FreeBSD does not have a menu-driven configuration system accessible by running make config, although it does have a plethora of options described in /usr/ports/mail/exim/options. If using portupgrade, you can pass these options with the -m flag; for example: # portupgrade -m “WITH_CONTENT_SCAN=yes WITH_SASLAUTHD=yes WITH_DOMAINKEYS=yes” exim
To test the ruleset in /etc/pf.conf, do the following: sudo pfctl -n -f /etc/pf.conf sudo pfctl -n -v -f /etc/pf.conf The second pfctl command displays the rules you’ve created; however, it can be easy to miss a syntax error warning in the verbosity – the first command will make it easy to spot those. You can [...]
When upgrading via a patch, installing the patch can be done by adding a “DESTDIR” argument to make:# make install DESTDIR=/u1/jail/192.168.0.12 When upgrading from source (Adapted from Upgrading a Jail from Source):# setenv JAIL /u1/jail/192.168.0.12 # mergemaster -pd -D $JAIL # cd /usr/src && make installworld DESTDIR=$JAIL # mergemaster -svd -D $JAIL
In FreeBSD’s /etc/default/rc.conf, the location of the rc.conf system configuration files is defined in the variable rc_conf_files. If you’re modularizing your rc.conf files – say, for use with Cfengine – you may be tempted to change the value of rc_conf_files in /etc/rc.conf or/etc/rc.conf.local. However, this change will not be picked up by itself – you need to call source_rc_confs after changing rc_conf_files, similar to this: rc_conf_files=”/etc/rc.conf /etc/rc.conf.local /etc/rc.conf.amd” [...]