FreeBSD PXE Network Install

Sometimes you need to perform a network installation (i.e. when no USB or DVD drive is allowed to boot, but you can boot PXE). In case of FreeBSD you can use DNSMASQ to serve the DHCP that will assign the initial client address and configuration along with PXE boot image served over tFTP. At this point you will have bootloader running, so you can serve filesystem over NFS to obtain working environment and/or the installer..

  • Create a directory that will hold the target filesystem over network. In my case that was
    /usr/local/tftp/FreeBSD
  • Put OS/Installer files inside above directory
    cd /usr/local/tftp/FreeBSD
    wget http://(..)/file.iso
    7z x file.iso
  • Edit /etc/exports to export the filesystem over NFS
    /usr/local/tftp/FreeBSD -ro -alldirs -network 192.168.0.0
  • Install the dnsmasq
    pkg install dnsmasq
  • Setup the /usr/local/etc/dnsmasq.conf
    enable-tftp
    tftp-root=/usr/local/tftp/FreeBSD
    
    dhcp-range=192.168.0.50,192.168.0.60,255.255.255.0,1h
    dhcp-boot=boot/pxeboot
    dhcp-option=option:router,
    dhcp-option=option:root-path,/usr/local/tftp/FreeBSD
    
  • Restart services
    service nfsd onerestart
    service dnsmasq onerestart
  • In case you get bootloader running but troubles with NFS make sure that mountd is running. Also you can see who is using the NFS shares with
    showmount -a

PXE Boot always use initial DHCP/tFTP to fetch configuration and bootloader, so the first stage is similar and should work with other Operating Systems and Bootloaders as well, the rest is up to bootloader itself..

Mac OSX Bluetooth Modem resource busy

In case you wonder why your device does not connect as Modem via Bluetooth to the Mac OSX, or you cannot see COM port on Windows, your mobile device may not simply support or provide DUN (Dial Up Network) and/or SPP (Serial Port Profile) profile.

On Mac OSX I got following error, until I tried another device and/or starting by hand DUN service on a mobile/client machine:

cannot open /dev/cu.Bluetooth-Modem: Resource busy

Notes:

  • Read Bluetooth specification for Serial Port Profile.
  • Read Bluetooth specification for Dial-Up Network Profile.
  • Modern mobile phones / USB 3G dongles, unfortunately, do not provide direct AT/Hayes access to the Radio Modem anymore.
  • You can install DUN application for your smartphone, but it will be only a simple dummy wrapper imitating modem for simple applications, but they do not provide full modem functionality, beware, its a fake.
  • Its only necessary for devices to be paired first in order to get SPP/DUN working. If device does not provide serial port over bluetooth when devices are paired and online, probably its just not there implemented.

LanManager

Lanmanager to prosty system zarządzania dostępem do routera uniksowego, napisany na potrzeby sieci komputerowej, ułatwiający egzekwowanie opłat. W bardzo prosty sposób pozwala udostępnić połączenie internetowe oraz zasoby serwera jedynie wskazanym komputerom z sieci wewnętrznej.

Read More