User Tools

Site Tools


freebsd:freebsd_3tweaks

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
freebsd:freebsd_3tweaks [2025/01/16 09:31] azmanfreebsd:freebsd_3tweaks [2025/02/14 13:09] (current) azman
Line 2: Line 2:
  
 Maybe useful to some... Maybe useful to some...
 +
 +===== ZeroConf =====
 +
 +  * avahi & multicast dns <code>pkg install -y avahi-app nss_mdns</code>
 +  * enable avahi daemon in ''rc.conf'':<code>
 +avahi_daemon_enable="YES"</code>
 +  * modify the ''hosts:'' line in ''nsswitch.conf'':<code>
 +hosts: files dns mdns</code>
 +
 +===== User Account =====
 +
 +  * by default root shell is csh and user is sh - edit .shrc to get prettier prompt<code>
 +  PS1="`whoami`@\H:\w\$ "</code>
 +  * (IF using slim) to enable x environment after slim login, create ''~/.xinitrc'' for each user:<code>
 +  exec /usr/local/bin/mate-session</code>
 +
  
 ===== Git ===== ===== Git =====
Line 82: Line 98:
 # netstat -an | grep 3306 # netstat -an | grep 3306
 # sockstat -4 -6 | grep 3306</code> # sockstat -4 -6 | grep 3306</code>
 +
 +===== Label for Partitions/Slices =====
 +
 +This is nice to have in / etc/ fstab when device assignment may change (e.g. usb drive on different machine may be assigned differently)
 +
 +For ufs,<code># tunefs -L <label> /dev/da0p?</code>
 +
 +To check if assigned,<code># ls /dev/ufs</code>
 +
 +For swap,<code># glabel label <label> /dev/da0p?</code>
 +
 +To check if assigned,<code># ls /dev/label</code>
 +
 +Then, / etc/ fstab entry can be like,<code>
 +/dev/label/<label> none swap sw 0 0
 +/dev/ufs/<label> / ufs rw 1 1
 +</code>
 +
 +===== Disk Utility ''gpart'' =====
 +
 +Show partition
 +
 +<code># gpart show</code>
 +
 +Resize partition
 +
 +<code># gpart resize -i 3 da0</code>
 +
 +Not really gpart stuff, but don't forget to grow FS to fit new size
 +
 +<code># growfs /dev/da0p3</code>
 +
 +===== Access to Linux ExtFS =====
 +
 +At the moment, full R/W access for Ext2, Journal-less for Ext3 and R/O for Ext4.
 +
 +<code>
 +# kldload ext2fs
 +# mount -t ext2fs /dev/<slice> <mount-path>
 +</code>
  
 ===== Creating Disk Layout for Bootable USB ===== ===== Creating Disk Layout for Bootable USB =====
  
-{{page>freebsd:create_usbdisk_layout&noheader}}+{{page>freebsd:freebsd_prep_bootusb&noheader}}
  
freebsd/freebsd_3tweaks.1736991060.txt.gz · Last modified: by azman