Maybe you’ve found white spaces in your filenames and run into problems trying to delete them.
Archive for June, 2003
Spaces in the file name
Saturday, June 28th, 2003Selecting mirrors (from gentoo.org)
Saturday, June 28th, 2003As Gentoo’s userbase grows, a common complaint is the slowdown of its primary mirrors. Many people in the community have responded, adding more mirrors to help distribute the load.
Disk Information utility
Monday, June 2nd, 2003Recently I have discovered this little and cool utility, similar to df but with some extra features and a bit clear output. The utility is di, the disk information.
From the man pages…
di displays usage information on mounted filesystems. Block values are reported in megabytes (1024k bytes) by default, but may be changed. If file is specified, the usage information for the partition on which file is located is printed.
As usual, to install the utility emerge the package…
emerge di
For a basic usage simply type…
kranpak root # di
Filesystem Mount Megs Used Avail %used fs Type
/dev/hda1 / 4102.4 202.9 3899.4 5% reiserfs
tmpfs /dev/shm 376.7 0.0 376.7 0% tmpfs
/dev/hda3 /home 3106.2 1362.5 1743.7 44% reiserfs
tmpfs /mnt/.init.d 2.0 0.0 2.0 1% tmpfs
/dev/hda8 /tmp 2102.2 34.6 2067.6 2% reiserfs
/dev/hda2 /usr 5106.4 3246.0 1860.4 64% reiserfs
/dev/hda5 /var 6000.6 2621.8 3378.9 44% reiserfs
The first thing here is that, as opposed to df you have the info regarding your filesystem type at first sight (compare this with df -t reiserfs).
Here are some of the switches a like:
-s [ s|n|r ], output sorted/unsorted/reversed
-t, print totals
-A, print all fields
There are a lot more switches (i.e. to format the output -very nice), so take a look at man pages. As part of the packages you’ll find the mi utility that will display info on the mounted filesystem (man mi).
Avoiding nimdas and alike
Sunday, June 1st, 2003If you have your Apache listening to the outside world probably you have received and seen in your logs these anoying entries regarding nimdas, redcodes and so.
As those kiddies really bother me I have made some modifications in my Apache config file.
Although there are other approaches to this problem, I find this one easy and clean.
Edit your httpd config file and add the following:
SetEnvIf Request_URI MSADC imbecil
SetEnvIf Request_URI scripts imbecil
SetEnvIf Request_URI default.ida imbecil
SetEnvIf Request_URI .exe$ imbecil
SetEnvIf Request_URI .dll$ imbecil
SetEnvIf Request_URI .dll$ imbecil
SetEnvIf Request_URI cgi-bin msadc imbecil
CustomLog /var/log/httpd/imbecil.log common env=imbecilErrorLog /var/log/httpd/error.log
CustomLog /var/log/httpd/access.log common env=!imbecil
This will log your kiddies in imbecil.log, so you can take further measures. Bear in mind that requests behind a proxy will be masked by this proxy.
Have a good approach to this problem?
A little clarification using emerge
Sunday, June 1st, 2003When I first start using emerge, I could not understand some of the behaviour of this tool. For example, when I tried to emerge OpenOffice…
kranpak root # emerge -p openoffice
These are the packages that I would merge, in order:
Calculating dependencies …done!
[ebuild N ] net-print/cups-1.1.18-r4
[ebuild N ] app-shells/tcsh-6.12-r2
[ebuild N ] app-office/openoffice-1.0.3-r1
And then I tried…
kranpak root # emerge -pu openoffice
These are the packages that I would merge, in order:
Calculating dependencies …done!
[ebuild N ] app-shells/tcsh-6.12-r2
[ebuild N ] net-print/cups-1.1.18-r4
[ebuild U ] x11-misc/ttmkfdir-3.0.9 [3.0.4]
[ebuild U ] dev-libs/expat-1.95.6-r1 [1.95.4]
[ebuild U ] media-libs/fontconfig-2.2.0-r2 [2.1]
[ebuild U ] x11-base/xfree-4.3.0-r2 [4.2.1-r2]
[ebuild N ] app-office/openoffice-1.0.3-r1
Why the difference? Is there any thing wrong? What is the difference between installing OpenOffice and updating it?
Well, here goes an explanation (thanks to spider from gentoo)…
The -pu option will check dependencies downwards from OpenOffice (as it should) and since you are updating it will note you have an older version than the currently available one, and update each package on its way down into the tree.
The “install” will only make sure you have at least the least possible version for satisfaction, not update them.