At first, there seems have a bug on Ubuntu 14.04.
launchpad post
I set .Xmodmap like this.
.Xmodmap:
remove Control = Caps_Lock
remove Lock = Control_L
clear Control
clear Lock
keycode 37 = Caps_Lock NoSymbol Caps_Lock
keycode 66 = Control_L NoSymbol Control_L
!keysym Control_L = Caps_Lock
!keysym Caps_Lock = Control_L
add Control = Control_L
add Lock = Caps_Lock
When login, it's loaded gracefully.
And, what is about console?
# showkey
# dumpkeys > switchcodemap
# vi switchcodemap
# mv switchcodemap /etc/console-setup/cached.kmap.gz
you can find out which code keys has with 'showkey' command.
The consoles have another keymap from Xwindows.
Enjoy.
Thursday, October 8, 2015
Thursday, September 24, 2015
NetBSD pkg download is auto unzipped with Chrome
NetBSD pkg download is auto unzipped with Chrome because Chrome gets content-type: x-tar, which is different from the download source - tgz. Chrome doesn't change its name and it confused me.
Wednesday, September 16, 2015
How to make Dansguardian allow swf objects
Add swf at the last of the file.
/etc/dansguardian/lists/exceptionextensionlist
It needs service restart.
/etc/dansguardian/lists/exceptionextensionlist
It needs service restart.
Monday, August 31, 2015
FreeBSD panic ffs_valloc dup alloc for samba4
After setup samba4 on FreeBSD10, starting samba cause panic.
panic: ffs_valloc: dup alloc
UFS journaling and soft updates seemed to crash at some duplication found.
Setting disable the journaling option works.
Boot at single user mode.
# tunefs -p /
# tunefs -n disable /
# tunefs -j disable /
# mount -u -o rw,noacls /
# rm /.sujournal
# reboot -n
After repaired, system works well and then set journaling again with no errors.
panic: ffs_valloc: dup alloc
UFS journaling and soft updates seemed to crash at some duplication found.
Setting disable the journaling option works.
Boot at single user mode.
# tunefs -p /
# tunefs -n disable /
# tunefs -j disable /
# mount -u -o rw,noacls /
# rm /.sujournal
# reboot -n
After repaired, system works well and then set journaling again with no errors.
Sunday, August 30, 2015
DansGuardian has 40 processes but small amount of ram rss
Squid3 and DansGuardian works now, and they run
PID RSS COMMAND
950 82936 /usr/sbin/dansguardian
953 83120 \_ /usr/sbin/dansguardian
961 82764 \_ /usr/sbin/dansguardian
... there runs more than 40 processes of dansguardian!
They have all 80MB resident size at each process, but free says only it uses 300MB. Why?
At first, check the parent process. It uses only heap.
# cat /proc/950/maps | cut -d' ' -f1 | awk -F\- '{p1="0x"$1;p2="0x"$2;printf ("%s %f\n", $1, 0.000001*(p2-p1) ) }' | sort -k+2 -n
...
7f91892c9000 2.097152
7f918982c000 2.097152
7f918ae81000 10.436608
7f9187a3a000 11.141120
00f36000 21.958656
7f91860f6000 26.492928
7f918403a000 34.320384
It surely gets 80MB and more ram size. Now check other process and it found they use same regions.
# grep 7f918403a000 /proc/*/maps
# grep 7f918403a000 /proc/*/maps
They share the parent's ram area with each other. Is it design?
Saturday, August 29, 2015
What's hostname in dhcpd.conf on NetBSD?
Hmm, I seem to misunderstand about dhcpd.conf for dhcpcd.conf. There has no hostname configuration in dhpcd.conf.
NetBSD 6.1 has no dhcpd.conf at default.
NetBSD 6.1 has no dhcpd.conf at default.
Wednesday, August 26, 2015
Ooops! defaultroute variable is a different name on NetBSD.
In NetBSD, defaultroute. But FreeBSD defaultrouter in rc.conf. Huf.
Tuesday, August 25, 2015
[WiFi] CRDA regualatory domain problem
Wiki says, the bandwidth of WiFi has to be set to 20Mhz for world-regulatory domain. You can confirm,
iw reg get
if it returns 00, your system is set to world-regulatory domain.
My Lubuntu frequently transited to the scanning state and failed to reconnect. I tried to fix it in many different ways, but the problem wasn't fixed.
Finally, I set my wireless-router for the bandwidth from 40MHz to 20MHz, and the problem seems to be fixed. Now it works perfectly.
Syslog messages were like that,
'regulatory not found .. and they can't be persist the connection and scanning network ... '
After half a day struggling, I made it.
iw reg get
if it returns 00, your system is set to world-regulatory domain.
My Lubuntu frequently transited to the scanning state and failed to reconnect. I tried to fix it in many different ways, but the problem wasn't fixed.
Finally, I set my wireless-router for the bandwidth from 40MHz to 20MHz, and the problem seems to be fixed. Now it works perfectly.
Syslog messages were like that,
'regulatory not found .. and they can't be persist the connection and scanning network ... '
After half a day struggling, I made it.
Subscribe to:
Posts (Atom)