FreeBSD good advices
FreeBSD good advices:
Flash
FreeBSD + Firefox + flash. It is not really my guide, I just collected some useful ideas into one.
- Install www/firefox
- Install www/linux-flashplugin7
- Install devel/linuxthreads
- Install www/linuxpluginwrapper
- Download patch for rtld-elf:
# fetch http://www.jail.se/freebsd/rtld_dlsym_hack.diff- Apply the patch:
# cd /usr/src/libexec/rtld-elf patch < /path/to/patch make make install make clean- Create links:
# cd /usr/local/lib/browser_plugins rm libflashplayer.so flashplayer.xpt ln -s ../npapi/linux-flashplugin/flashplayer.xpt ln -s ../npapi/linux-flashplugin/libflashplayer.so- Add the following strings to /etc/libmap.conf:
[/usr/local/lib/npapi/linux-flashplugin/libflashplayer.so] libpthread.so.0 pluginwrapper/flash7.so libdl.so.2 pluginwrapper/flash7.so libz.so.1 libz.so.3 libstdc++-libc6.2-2.so.3 libstdc++.so.4 libm.so.6 libm.so.4 libc.so.6 pluginwrapper/flash7.so
sysctl
hw.ata.wc=1
I have FreeBSD 6.1 on my HP/Compaq nx9030 laptop. I've copied FreeBSD 6.1 iso file from one partition to another two times:0: time shown 175 s, mc - 2.74 Mb/sPlease, read ata(4) and tuning(7) for details. This option may be dangerous.
1: time shown 375 s, mc - 5,51 Mb/s
This options should be set before kernel start, i.e. use /boot/loader.conf
kern.corefile=/var/tmp/%N.core
kern.sugid_coredump=1
The first one controls the name of the file. %N is the process name, also available options are %P - PID, %U - UID.Just put this to /etc/sysctl.conf
FreeBSD traditionally uses %N.core by default.
Second one says that a process that changes user or group credentials whether real or effective should create a corefile. By default it will not.
FreeBSD
autologin
How to make some user login automatically?
- Add to the /etc/gettytab file the following strings:
test:\ :al=test:ht:np:sp#115200:test:\ - entry name, autologin will use this username;
al=test - autologin username;
ht - terminal has real tabs;
np - 8-bit chars;
(optional) sp#115200 - line speed;
- Edit /etc/ttys file:
ttyv0 "/usr/libexec/getty test" cons25 on secureUsual Pc changed with test.
DCOP
ksnapshot
My aim is to take screenshot of a selected region. I'm using ksnapshot which is a part of kdegraphics port, but ksnapshot is too interactive for me ;)
I'd like to have the following steps:After a few minutes I found the following way:hotkey -> region selection -> save dialog -> quit
It's easy to make simple script.
- Start ksnapshot using dcopstart:
# setenv pid `dcopstart ksnapshot`- Send signals using dcop:
Asks ksnapshot to set the grab mode to "Region":# dcop $pid interface setGrabMode 2- Start selection of a region:
# dcop $pid interface slotGrab- Save file dialog:
# dcop $pid interface slotSaveAs- Quit:
# dcop $pid interface exit
Feel free to contact, e-mail <keyhell@keyhell.org>




Post new comment