dd

8Gb MemStick, copy with dd, to *.iso
# dd if=/dev/da0 of=tmp/memstick.iso bs=??

Intel(R) Pentium(R) Dual  CPU  T2330  @ 1.60GHz (1596.01-MHz K8-class CPU)
real memory  = 2147483648 (2048 MB)

8952.149078 secs (907884 bytes/sec) (bs=512)
419.341845 secs (19381592 bytes/sec) (bs=1m)
427.454933 secs (19013730 bytes/sec) (bs=2m)

Write 733Mb file to MemStick
% dd if=/tmp/FreeBSD-9.1-RELEASE-amd64-memstick.img of=/dev/da1 bs=64k
85.640098 secs (8978571 bytes/sec) (bs=64k)

Cygwin

2011-04-01
c:\cygwin\bin\bash --login "c:\backup-script.sh"

AVRDUDE 6.3 and Arduino 1.0.6

2016-12-24
For the Arduino framework to work on FreeBSD, load the linux module. (Arduino Release Notes.)

To make the Arduino Uno work, install the device comms/uarduno, in my setup (as of 21th July 2011), use the patch found in FreeBSD PR, load the uarduno device.

For the Arduino Duemilanove, load the uftdi device.

Command line uploads with avrdude, in the examples below the blink.c object code blink.hex is uploaded.

The hex code from the Arduino IDE (after it is compiled/verified), is placed in "/tmp/build*/*.cpp.hex".

Arduino Duemilanove:
avrdude -V -F -c stk500v1 -p m328p -b 57600 -P /dev/cuaU0 -U flash:w:blink.hex
Arduino Uno:
avrdude -V -F -c stk500v1 -p m328p -b 115200 -P /dev/cuaU0 -U flash:w:blink.hex
To get the serial communication to the USB/Serial port, use "cu":
cu -l /dev/cuaU0 -s 9600

XFCE

2011-08-01
If missing all shortcuts and the Desktop, try to delete ".cache" in home directory.
(FreeBSD)


Mount FreeBSD filesystem on Debian

2011-08-24
In fstab:
# /dev/sda11      /media/freebsd          ufs     ufstype=ufs2,ro 0       0
# /dev/sda10      /media/freebsd_tmp      ufs     ufstype=ufs2,ro 0       0

..or from the commandline:

# mount -t ufs -o ufstype=ufs2,ro /dev/sda11 /media/freebsd/
# mount -t ufs -o ufstype=ufs2,ro /dev/sda10 /media/freebsd_tmp/

In my setup, FreeBSD /usr = /dev/sda11 and FreeBSD /tmp = /dev/sda10


FreeBSD Image to USB stick

Set the kern.geom.debugflags sysctl to be able to write a master boot record to the target device.

# sysctl kern.geom.debugflags=16

The .img file is not a regular file you copy to the memory stick. It is an image of the complete contents of the disk. This means that you cannot simply copy files from one disk to another. Instead, you must use dd(1) to write the image directly to the disk:

# dd if=FreeBSD-8.2-RELEASE-i386-memstick.img of=/dev/da0 bs=64k

FreeBSD on Laptop

pkg_info.txt, pkg_info listing


ImageMagick Screendump

$> sleep 15; import -window root MyScreenshot3.png

CD Image

dd the CD to an image file, i.e. BIG_CD.img.

Mount the cd image:

mount_cd9660 /dev/`mdconfig -f dskimg/BIG_CD.img` mnt

RAID1

2012-12-05
Initiate a RAID1 with one volume, and then insert next volume (which will be re-build). The "Intel" option is the metadata format, several others are available (graid(8)).

# graid label Intel hmj_data RAID1 /dev/da0p1 NONE
..or if both are existing:
# graid label Intel hmj_data RAID1 NONE NONE

This one got the "array" name (or Geom name: Intel-82bbbb27) "Intel-82bbbb27" and "label" "hmj_data", so when adding the next missing volume, use:

# graid insert Intel-82bbbb27 /dev/da1p1

The "Geom name" and "label" can be found by

# graid list

Then mount the raid area:

# mount /dev/raid/r0 /mnt

SSD with FreeBSD

Start with single user or rescue disc:

# gpart create -s gpt ada0
# gpart add -t freebsd-boot -s 512k -a4k -l ssdboot ada0
# gpart bootcode -b /boot/pmbr -p /boot/gptboot -i1 ada0
# gpart add -t freebsd-ufs -l ssdrootfs -b 1m -s 2g ada0
# gpart add -t freebsd-ufs -l ssdvarfs -a 1m -s 2g ada0
# gpart add -t freebsd-ufs -l ssdusrfs -a 1m ada0
# newfs -U -t /dev/gpt/ssdrootfs
# newfs -U -t /dev/gpt/ssdvarfs
# newfs -U -t /dev/gpt/ssdusrfs

..and then the fstab:

# Device                Mountpoint      FStype  Options         Dump    Pass#
/dev/gpt/ssdrootfs      /               ufs     rw              1       1
/dev/gpt/ssdvarfs       /var            ufs     rw              2       2
tmpfs                   /tmp            tmpfs   rw,mode=01777   0       0
/dev/gpt/ssdusrfs       /usr            ufs     rw              2       2

..and then swap area:

# mkdir /usr/swap
# dd if=/dev/zero of=/usr/swap/swap bs=128k count=32768

..and the rc.conf:

swapfile="/usr/swap/swap"

..all from Warren Block, see this link.

Regarding the UEFI BIOS... it might be necessary to activate the boot disk with:

gpart set -a active adaX

FreeBSD Default Sound Unit "0"

2014-06-05
Headset device on Asus B85M-G is the default unit 0 (back), to set speaker sound unit to 1 (front):


# sysctl hw.snd.default_unit=1


FreeBSD with Claws-mail and GPG

2014-06-05
Install gnugpg, gpgme, enchant, pinentry and claws-mail-pgp.


FreeBSD with Claws-Mail and hunspell

2018-03-24
Install hunspell, dictionary en-hunspell and find the da.dic + da.aif on stavekontrolden, both to be placed in /usr/local/share/hunspell/


FreeBSD with radeonkms graphics driver.

Check the FreeBSD Wiki


FreeBSD with Nikon DSLR.

2017-02-01
Add a line to /etc/devfs.rules:
add path 'usb/*' mode 0660 group operator


SQLite3 Compiler.

2017-03-11
Use the gcc compiler, clang will not work... also add -lsqlite3 to the command line.


Claws-Mail Spell Checking.

2017-06-04
Use hunspell and get the danish dictionaries, search for hunspell-da.


DVB Radio NooElec

2017-11-26
Add a line to /etc/devfs.rules:
add path 'dvb/*' mode 0660 group operator


rtl_sdr to sound file

Pipe to file /tmp/wbfm.wav:
rtl_fm -f 88700000 -M wbfm - | \
ffmpeg -f s16le -ar 17000 -ac 2 -i - /tmp/wbfm.wav

OpenBSD dump/restore

2019-06-13
To restore from a dump file that has several volumes, volume 1 with file name vol_01:

restore -i -f vol_01

..when asked for volume, start with 1:

Specify next volume #: 1

..the volume "vol_01" is read and at next request for volume #, supply next in the sequence, this time 2:

Specify next volume #: 2

..and add "vol_02", see below:

Mount tape volume 2
Enter ``none'' if there are no more tapes
otherwise enter tape name (default: vol_01) vol_02

..remember to add directory as specified in the default path.


Internet Radio

Yamaha CD-NT670D


Velkommen

pmwiki.org

edit SideBar
pmwiki-2.2.120



Edit - History - Print - Recent Changes - Search
Page last modified on November 09, 2019 at 15:08 +0000