Category: Work related
Get rid of “\\n” in files
cat fn.txt | tr ‘\\\n’ ‘ ‘ > fn.1.txt sed -i ‘s/ //g’ fn.1.txt mv fn.1.txt fn.txt
Launch X11 xterm windows from anywhere UNIX
tell application “X11” activate end tell
Fedora: Starting abrt daemon: abrtd: Failed to start: timeout waiting for child
This is listed as Bug 524469 but never a real solution was drawn. https://bugzilla.redhat.com/show_bug.cgi?id=524469 However, this is an easy thing, that the user abrt was not created. This cab be figured by running $ abrtd -vvvv Cure: create the user abrt, as: abrt:x:399:398::/etc/abrt:/sbin/nologin Also you will need to make sure that certain lines exist in group, […]
Use md5 checksum to identify malware
1) download md5deep from here: http://md5deep.sourceforge.net/#download 2) run the DOS script: @echo off if exist c:\out.txt del c:\out.txt for /r c:\ %%a in (*) do (md5deep %%~sa >> c:\out.txt) This will take hours, if you have plenty files. Note: You can change the c:\out.txt to anything you will feel more comfortable, and use like (*.exe […]
Limited by AUTH_SYS, NFS can only handle 16 groups for each user
http://www.insectnation.org/articles/2007/05/08/linux-nfs-16-group-limit/ unless you’d like to suffer the kerberos auth.
linux Oops: I deleted an improtant file, can I undelete?
Linux does not offer a file undelete or unerase mechanism, especially in command line. To undelete a really deleted file, it take guru’s work like in http://www.cyberciti.biz/tips/linuxunix-recover-deleted-files.html This is the last thing one can do. However, if you take a few precautions, you may save yourself easily. There is a small package named ptrash, which […]
fsck: Couldn’t fix parent of inode : Couldn’t find parent directory entry
In linux file system, when file system error happens, the first choice is to do an fsck of the unmounted file system. Usually, fsck -y /dev/sdxx at boot time should be able to fix everything, if the FS has not been severely damaged. Occasionally, as reported as Debian bug list #478546 at http://groups.google.com/group/linux.debian.bugs.dist/browse_thread/thread/dc48335d2ca42b66 fsck returns […]
RHEL5 – yum update works but pup and yum list-security does not
The RHEL5 machines under my administration experienced an interesting error. If running pup, whenever there are updates exist, it crashes with the error: SyntaxError: not well-formed (invalid token) The error message will be things like # yum list-security Loading “rhnplugin” plugin Loading “security” plugin Setting up repositories rhel-i386-server-cluster- 100% |=========================| 1.4 kB 00:00 rhel-i386-server-5 100% […]
Multiple Cygwin coexist
in one cygwin, do mount -m > c:/somewhere/mount-cygwin1 in another cygwin, do mount -m >c:/somewhere/mount-cygwin2 then edit their cygwin.bat, add lines umount -A sh C:/somewhere/mount-cygwin1 in the first cygwin.bat after @echo off line then edit the second cygwin.bat, add lines umount -A sh C:/somewhere/mount-cygwin2 in the cygwin.bat after @echo off line now two versions of […]
How do I defragment “C:\$Extend\$UsnJrnl:$J:$DATA”?
This huge file is used by Windows to track changes in other files and cannot be defragmented. You can delete it by entering the following on the Run commandline (Windows 2003/XP/Vista, not Windows 2000), it can take several minutes to finish: fsutil usn deletejournal /n c: