I was searching on how to disable the "Windows XP" screen saver on the login screen, and simply have it use the "Blank Screen" Screen-saver.
The url this post links to, describes where (near the bottom of the page) to go in the registry to edit this setting, but didn't mention how to set it to the blank screen, add my recipe to it to get the blank / black screen screen-saver.
Browse to the following key with regedit: HKEY_USERS\.DEFAULT\Control Panel\Desktop
In the right side of the window, change the SCRNSAVE.EXE entry by double clicking on it, to contain:
C:\WINDOWS\system32\scrnsave.scr
That's all.... this can also be used to change to any other screen saver, just point it to the appropriate file.
WHY?: I did this on some vmware virtual windows XP machines to reduce any extra load the screen savers would put on them while they were sitting at the login screens.
EDIT: another link to microsoft on the subject:
http://support.microsoft.com/kb/314493
Monday, September 29, 2008
Monday, July 7, 2008
mouse keys in virtual pc 2007 and ubuntu hardy heron 8.04
a few notes about getting ubuntu hardy heron 8.04 running under Virtual PC 2007 and using it via a remote desktop connection to the virtual pc host computer (or at least to get the installation done successfully with custom partitioning).
to boot up the hardy heron 8.04 (kubuntu-desktop in my case) live CD successfully without virtual pc complaining about a processor error and promptly crashing the virtual instance, you need to follow these steps:
1. choose your language upon first boot of the live CD inside the virtual pc instance (english in my case)
2. press F4 and choose the Safe Graphics mode option (down arrow to it, then enter)
3. press F6 and add: "noreplace-paravirt" to the command line that shows on the screen (without the quotes)
4. press Enter to continue the process
The live cd should boot to a linux desktop (KDE or Gnome or ... depending on which live CD you are using)
to continue the installation, choose the install icon on the desktop, at this point, you may find it hard to use the mouse (via remote desktop connection to the windows host machine), so I suggest turning on mouse keys to use the number pad as a mouse instead, following these steps:
press the left-alt + left-shift + num-lock buttons together, at first, your windows host machine will ask about turning on mouse keys, I chose to disable the mouse key shortcut (in the windows host machine that I was RDP'd into), and closed out the mouse keys configuration menus, and then repeated the process of pressing left-alt + left-shit + num-lock again, and this time, the linux session recognized it (KDE in my case) and brought up a configuration window for it, I used the keyboard and pressed tab to change focus to "continue", and then spacebar for choosing continue. Now if num-lock is turned on, i can use the number pad to move my mouse around (5 is left click btw).
to boot up the hardy heron 8.04 (kubuntu-desktop in my case) live CD successfully without virtual pc complaining about a processor error and promptly crashing the virtual instance, you need to follow these steps:
1. choose your language upon first boot of the live CD inside the virtual pc instance (english in my case)
2. press F4 and choose the Safe Graphics mode option (down arrow to it, then enter)
3. press F6 and add: "noreplace-paravirt" to the command line that shows on the screen (without the quotes)
4. press Enter to continue the process
The live cd should boot to a linux desktop (KDE or Gnome or ... depending on which live CD you are using)
to continue the installation, choose the install icon on the desktop, at this point, you may find it hard to use the mouse (via remote desktop connection to the windows host machine), so I suggest turning on mouse keys to use the number pad as a mouse instead, following these steps:
press the left-alt + left-shift + num-lock buttons together, at first, your windows host machine will ask about turning on mouse keys, I chose to disable the mouse key shortcut (in the windows host machine that I was RDP'd into), and closed out the mouse keys configuration menus, and then repeated the process of pressing left-alt + left-shit + num-lock again, and this time, the linux session recognized it (KDE in my case) and brought up a configuration window for it, I used the keyboard and pressed tab to change focus to "continue", and then spacebar for choosing continue. Now if num-lock is turned on, i can use the number pad to move my mouse around (5 is left click btw).
Thursday, April 3, 2008
Installing Ubuntu 8.04 LTSP OR Edubuntu
I was attempting to setup an LTSP server and had decided to go the "easy" way by simply installing edubuntu (which includes a preconfigured LTSP server with some additional preinstalled packages aimed at education users (8 to 16 year old students from what someone mentioned in the IRC channel #edubuntu on the freenode IRC network (irc.freenode.net).
Unfortunately, with the new version of ubuntu (8.04) that is being released at the end of April 2008, they've changed everything around, and there is no longer a separate edubuntu (server) installation disk (per say), and you don't use the standard ubuntu-server disk either..... so how how then, do you install an edubuntu server or any other LTSP server (the advantage of the newly christened way of going about setting up edubuntu/ltsp... )? Read on to find out.. I originally spent 20-30 minutes googling for information and was coming up rather short on answers, until I finally decided to give the IRC channels a try, and happily (and quickly) found out the required details:
First things first, you need to download the pieces:
(Choose i386 or amd64 based on your hardware (64bit or 32bit), and/or based on personal choice. Personally I choose i386 initially for reasons that include better compatibility with certain programs and compiling programs from source without extra hassle, this should eventually fade as 64bit becomes the standard.. but, until then, I'll stick with builds that make my life less stressful! :) )
Required for Ubuntu 8.04 LTSP Server:
1. download the ubuntu-8.04-alternate CD Image
Required for Ubuntu 8.04 Edubuntu (LTSP) Server:
1. download the ubuntu-8.04-alternate CD Image
2. download the edubuntu-8.04-addon CD Image
Burn the Images that you need using your favorite burning software.
Installation of LTSP Server:
1. Put the ubuntu-8.04-alternate CD/DVD in your systems CD/DVD Reader.
2. Turn the machine on and let it get to the Ubuntu CD Install menu.
3. Don't get carried away and hit enter yet... instead, after choosing your preferred language, press the 'F4' key on your keyboard, this should bring up a menu, choose the LTSP option.
4. Press enter to start the installation.
sidenote: depending on how many network cards (suggested defaults included for 2) are in the system, some more interaction may be required during installation. If you want the simplest installation, just make sure you have two network cards in the system.
5. Congratulations, you now have an LTSP Server... this is all this post covers, as this is as far as I've gotten with my own LTSP installation, if you wanted an edubuntu LTSP server, read on to step 6, otherwise, enjoy your standard LTSP server:
6. After the installation, and rebooting, and logging into the desktop, insert the edubuntu addon CD/DVD into the system.
7. A popup should come up asking if you'd like to install the Extensions
8. After agreeing to install the extensions, an 'add-remove applications' dialog will popup, presenting the CD Contents sorted by category.
9. Select the edubuntu desktop category and toggle the checkbox next to the edubuntu-desktop package in the right window.
10. After all the install processes finish, restart your server to make the edubuntu artwork take effect.
11. Congratulations, you now have an Ubuntu 8.04 Edubuntu LTSP Server.
Note: some of these steps are near verbatim from the original article I was pointed to (and the one that this post links to), since I couldn't have said it any better :)
Now all I need to do is setup the client side of things :)
Unfortunately, with the new version of ubuntu (8.04) that is being released at the end of April 2008, they've changed everything around, and there is no longer a separate edubuntu (server) installation disk (per say), and you don't use the standard ubuntu-server disk either..... so how how then, do you install an edubuntu server or any other LTSP server (the advantage of the newly christened way of going about setting up edubuntu/ltsp... )? Read on to find out.. I originally spent 20-30 minutes googling for information and was coming up rather short on answers, until I finally decided to give the IRC channels a try, and happily (and quickly) found out the required details:
First things first, you need to download the pieces:
(Choose i386 or amd64 based on your hardware (64bit or 32bit), and/or based on personal choice. Personally I choose i386 initially for reasons that include better compatibility with certain programs and compiling programs from source without extra hassle, this should eventually fade as 64bit becomes the standard.. but, until then, I'll stick with builds that make my life less stressful! :) )
Required for Ubuntu 8.04 LTSP Server:
1. download the ubuntu-8.04-alternate CD Image
Required for Ubuntu 8.04 Edubuntu (LTSP) Server:
1. download the ubuntu-8.04-alternate CD Image
2. download the edubuntu-8.04-addon CD Image
Burn the Images that you need using your favorite burning software.
Installation of LTSP Server:
1. Put the ubuntu-8.04-alternate CD/DVD in your systems CD/DVD Reader.
2. Turn the machine on and let it get to the Ubuntu CD Install menu.
3. Don't get carried away and hit enter yet... instead, after choosing your preferred language, press the 'F4' key on your keyboard, this should bring up a menu, choose the LTSP option.
4. Press enter to start the installation.
sidenote: depending on how many network cards (suggested defaults included for 2) are in the system, some more interaction may be required during installation. If you want the simplest installation, just make sure you have two network cards in the system.
5. Congratulations, you now have an LTSP Server... this is all this post covers, as this is as far as I've gotten with my own LTSP installation, if you wanted an edubuntu LTSP server, read on to step 6, otherwise, enjoy your standard LTSP server:
6. After the installation, and rebooting, and logging into the desktop, insert the edubuntu addon CD/DVD into the system.
7. A popup should come up asking if you'd like to install the Extensions
8. After agreeing to install the extensions, an 'add-remove applications' dialog will popup, presenting the CD Contents sorted by category.
9. Select the edubuntu desktop category and toggle the checkbox next to the edubuntu-desktop package in the right window.
10. After all the install processes finish, restart your server to make the edubuntu artwork take effect.
11. Congratulations, you now have an Ubuntu 8.04 Edubuntu LTSP Server.
Note: some of these steps are near verbatim from the original article I was pointed to (and the one that this post links to), since I couldn't have said it any better :)
Now all I need to do is setup the client side of things :)
Thursday, March 27, 2008
Webalizer DNS problems (fails to resolve any domains)
I had the (mis)pleasure of reinstalling webalizer the other night on a server to run some stats, I ended up wasting a bunch of my time on a silly problem, and thought I should post my solution since my googled in vain for an answer.
Basically, the coles notes version: I had run a grep based on a particular domain name, on all the (several gigs) of apache2 log files sitting in the log folder, in hopes of creating just a log for a particular domain. Unfortunately, I forgot that when grepping multiple files (using filename wildcards on grep command line), that it will output the filename that any search results are found in (once per line of text found). I didn't notice this happening, since I piped the output to a new file. I later went on to try running webalizer on this file, only to find that the DNS wasn't working properly, and it wasn't resolving any of the visitor's IP's.
After googling, it became obvious that this was/is a common problem for webalizer (DNS issues), unfortunately for me, my erroneous log files were the cause of the problem, and I wasted *alot* of time trying to rebuild webalizer from source using the suggested --enable-dns option, tried downloading a newer src rpm from a newer distribution (opensuse 10.0 based system, tryed 10.2 or 10.3 src), unfortunately it had different requirements that didn't seem solveable with Opensuse 10.0.
I eventually actually looked at my log file I was trying to process (more closely.. as I had looked at it several times before... without noticing my/the error). I went on to also determine that webalizer doesn't like the vhost at the beginning of each line (don't quote me on this.. I may be dreaming.. it was late... ), so I went on to find a way to remove that as well.
Tools/methods to fix the problems:
To remove the filename "access_log-20060131:"(and variations (dates) thereof) from in front of the vhost name on each line (note, make sure all the original log filenames were the same number of characters length for this search/delete to work and not miss any, otherwise it could be modified a bit I guess):
sed -e 's/access_log-2006.....//g' testlog
This removed the filename and the colon (:) from in front of any vhost names in the log file.
To remove the vhost names for webalizer (once again, not positive you need to do this, but I wanted to make sure I had only gotten log entries that originated from the particular vhost.. my grep may have caught some that were referred by the particular vhost to other vhost domains.. so this step eliminates that problem:
split-logfile2 < testlog
split-logfile2 splits a vhost_combined format apache2 logfile into separate files based on the vhost names contained in the logfile, and also removes the vhost name from the first part of each line, since the file it outputs to (for each domain) is based on the vhost name, this isn't an issue in terms of recognizing what domain each log is for.
I hadn't known about split-logfile2 before all of this, and now that I do, it will definitely come in handy down the road.
After all this, webalizer was more then happy to finally parse the logs, and even reverse dns all the IP's providing much better results in terms of visitor information, etc.
on a side note, in my several hours of pissing around, I ran across several programs / projects / packages that either have forked off of webalizer, or forked off of other common log analyzers (seems there are many), and I will try to put a post up with what I found... if only for my own reference later. Webalizer results really do seem kind of basic after all is said and done, so finding another analyzer suite (I've used awstat before as well) may be in the cards if I want to garner more information... another alternative is also google analytics of course, but this involves having it in the pages being served, and during the fact of things happening.. its always nice to be able to process log files after the fact using tools such as webalizer and awstats.
Basically, the coles notes version: I had run a grep based on a particular domain name, on all the (several gigs) of apache2 log files sitting in the log folder, in hopes of creating just a log for a particular domain. Unfortunately, I forgot that when grepping multiple files (using filename wildcards on grep command line), that it will output the filename that any search results are found in (once per line of text found). I didn't notice this happening, since I piped the output to a new file. I later went on to try running webalizer on this file, only to find that the DNS wasn't working properly, and it wasn't resolving any of the visitor's IP's.
After googling, it became obvious that this was/is a common problem for webalizer (DNS issues), unfortunately for me, my erroneous log files were the cause of the problem, and I wasted *alot* of time trying to rebuild webalizer from source using the suggested --enable-dns option, tried downloading a newer src rpm from a newer distribution (opensuse 10.0 based system, tryed 10.2 or 10.3 src), unfortunately it had different requirements that didn't seem solveable with Opensuse 10.0.
I eventually actually looked at my log file I was trying to process (more closely.. as I had looked at it several times before... without noticing my/the error). I went on to also determine that webalizer doesn't like the vhost at the beginning of each line (don't quote me on this.. I may be dreaming.. it was late... ), so I went on to find a way to remove that as well.
Tools/methods to fix the problems:
To remove the filename "access_log-20060131:"(and variations (dates) thereof) from in front of the vhost name on each line (note, make sure all the original log filenames were the same number of characters length for this search/delete to work and not miss any, otherwise it could be modified a bit I guess):
sed -e 's/access_log-2006.....//g' testlog
This removed the filename and the colon (:) from in front of any vhost names in the log file.
To remove the vhost names for webalizer (once again, not positive you need to do this, but I wanted to make sure I had only gotten log entries that originated from the particular vhost.. my grep may have caught some that were referred by the particular vhost to other vhost domains.. so this step eliminates that problem:
split-logfile2 < testlog
split-logfile2 splits a vhost_combined format apache2 logfile into separate files based on the vhost names contained in the logfile, and also removes the vhost name from the first part of each line, since the file it outputs to (for each domain) is based on the vhost name, this isn't an issue in terms of recognizing what domain each log is for.
I hadn't known about split-logfile2 before all of this, and now that I do, it will definitely come in handy down the road.
After all this, webalizer was more then happy to finally parse the logs, and even reverse dns all the IP's providing much better results in terms of visitor information, etc.
on a side note, in my several hours of pissing around, I ran across several programs / projects / packages that either have forked off of webalizer, or forked off of other common log analyzers (seems there are many), and I will try to put a post up with what I found... if only for my own reference later. Webalizer results really do seem kind of basic after all is said and done, so finding another analyzer suite (I've used awstat before as well) may be in the cards if I want to garner more information... another alternative is also google analytics of course, but this involves having it in the pages being served, and during the fact of things happening.. its always nice to be able to process log files after the fact using tools such as webalizer and awstats.
"Upgraded" from Kingston 4GB USB Flash Drive to Patriot Xporter 8GB USB Flash Drive
I traded "up" and got a Patriot XPORTER 8GB (not the XT designated model) USB Flash drive, to replace my "little" 4gb Kingston USB Flash Drive. I had only purchased the 4gb a month or two ago for $20, and the 8gb xporter was $30 on sale last week, so thats why I picked it up, plus I have a friend that could use the 4gb drive.
While the space is an upgrade, the performance is around 50% when compared to the kingston. The kingston can read (most of the drive) at 33mb/sec, while the Patriot Xporter only manages a steady 14mb/sec across the whole drive. Writing is nearly half of the kingston also, though I can't recall what I calculated for write speeds, since the program I used (HDTACH) only supports reading tests (RAW, not filesystem based as far as I know), and I just manually calculated the writing speeds by writing a 150MB file to each drive and timed them.
In this case, I'm willing to accept the speed downgrade for the doubled capacity, allowing me to store/transfer some rather large files when I need to, or simply not have to "clean it up" as often, in order to make sure I have room on it.
While the space is an upgrade, the performance is around 50% when compared to the kingston. The kingston can read (most of the drive) at 33mb/sec, while the Patriot Xporter only manages a steady 14mb/sec across the whole drive. Writing is nearly half of the kingston also, though I can't recall what I calculated for write speeds, since the program I used (HDTACH) only supports reading tests (RAW, not filesystem based as far as I know), and I just manually calculated the writing speeds by writing a 150MB file to each drive and timed them.
In this case, I'm willing to accept the speed downgrade for the doubled capacity, allowing me to store/transfer some rather large files when I need to, or simply not have to "clean it up" as often, in order to make sure I have room on it.
Install Native Ubuntu system from the comfort of Windows GUI/System using WUBI
http://wubi-installer.org/
A friend posted this link to me, its bascially a GUI windows (and linux) based application that allows a user to install Ubuntu directly on a Windows system, on the windows filesystem (using large file(s)).
Later on, you can move the ubuntu system onto its own partition if you want a speed upgrade, as well as greater security of your data in case of power outages, since one of the notes about running ubuntu in a file on the windows filesystem, it is more prone to errors during hard shutdown / reboots then it would normally be if it were installed on its own partition.
Looks cool... I've used some other ones before (forget the names), I imagine this one is either an evolution of the ones I used, seems this stuff is always getting better and easier.
Oh yeah, and whats kinda cool, is that you can simply go to Add/Remove programs in windows if you want to remove the linux installation later, in case you want to try a different version, or need the space.
A friend posted this link to me, its bascially a GUI windows (and linux) based application that allows a user to install Ubuntu directly on a Windows system, on the windows filesystem (using large file(s)).
Later on, you can move the ubuntu system onto its own partition if you want a speed upgrade, as well as greater security of your data in case of power outages, since one of the notes about running ubuntu in a file on the windows filesystem, it is more prone to errors during hard shutdown / reboots then it would normally be if it were installed on its own partition.
Looks cool... I've used some other ones before (forget the names), I imagine this one is either an evolution of the ones I used, seems this stuff is always getting better and easier.
Oh yeah, and whats kinda cool, is that you can simply go to Add/Remove programs in windows if you want to remove the linux installation later, in case you want to try a different version, or need the space.
centos 4.4 lvm snapshots crash system when they become full (run out of space)
Just a note:
On a CentOS 4.4 server, lvm snapshots that eventually became full (and hence invalid), would crash a system. This problem seems to be fixed in Centos 4.6 (I didn't try 4.5). I can now run snapshots that eventually run out of space, and successfully lvremove them without crashing the system.
On a CentOS 4.4 server, lvm snapshots that eventually became full (and hence invalid), would crash a system. This problem seems to be fixed in Centos 4.6 (I didn't try 4.5). I can now run snapshots that eventually run out of space, and successfully lvremove them without crashing the system.
Monday, April 16, 2007
opensuse suse 10 OSS phantom OR ghost 169.254.0.0 network
Opensuse 10 / 10.1 / 10.2 phantom 169.254.0.0 network in route list (route -n).
Post I found related to the problem:
http://lists.opensuse.org/opensuse-autoinstall/2005-01/msg00116.html
Explanation linked to from other post:
http://en.wikipedia.org/wiki/Zeroconf
I didn't bother reading all of it, but it did clear up the fact that it seems to be part of the system and nothing to worry about. I couldn't find it in yast's network config tool anywhere.. so was wondering why it was there.
Post I found related to the problem:
http://lists.opensuse.org/opensuse-autoinstall/2005-01/msg00116.html
Explanation linked to from other post:
http://en.wikipedia.org/wiki/Zeroconf
I didn't bother reading all of it, but it did clear up the fact that it seems to be part of the system and nothing to worry about. I couldn't find it in yast's network config tool anywhere.. so was wondering why it was there.
opensuse suse 10 OSS ntop 3.2 recompile from source
After trying to download the ntop 3.2 source package from opensuse 10.2 (this server is opensuse 10.0), building it, and upgrading/installing it (rpm -Uvh ntop-3.2.xxx) over the current ntop 3.1.50 that was installed, I kept getting an error complaining about libmyrrd-3.2.so, like the following, the rest of ntop would work, just no RRD graphs, etc:
Mon Apr 16 03:38:21 2007 **WARNING** Unable to load plugin '/usr/lib/ntop/plugins/rrdPlugin.so'
Mon Apr 16 03:38:21 2007 **WARNING** Message is 'libmyrrd-3.1.50.so: cannot open shared object file: No such file or directory'
After 10 or 20 minutes of futzing around, trying to recompile ntop 3.2 a few times, I decided to try removing ntop entirely from the system, *THEN* compiling the fresh copy. After compilation, I installed the ntop 3.2 from the newly created binary rpm in /usr/src/packages/RPMS/i586/ntop-3.2.xxxx.rpm, tried running it again, and it didn't complain and RRD worked this time.
Mon Apr 16 03:38:21 2007 **WARNING** Unable to load plugin '/usr/lib/ntop/plugins/rrdPlugin.so'
Mon Apr 16 03:38:21 2007 **WARNING** Message is 'libmyrrd-3.1.50.so: cannot open shared object file: No such file or directory'
After 10 or 20 minutes of futzing around, trying to recompile ntop 3.2 a few times, I decided to try removing ntop entirely from the system, *THEN* compiling the fresh copy. After compilation, I installed the ntop 3.2 from the newly created binary rpm in /usr/src/packages/RPMS/i586/ntop-3.2.xxxx.rpm, tried running it again, and it didn't complain and RRD worked this time.
SecureCRT CTRL-S silent input output CTRL-Q to restore
Sometimes while using SecureCRT, I notice that I accidentally hit CTRL-S ... this *seems* to make it so securecrt does not accept any more input, and you don't see any more output for the connection. CTRL-S actually happens to be SILENCE (or similar) mode, and makes it so you don't see what you type, or the output from those commands. I googled for the problem, and found this link:
http://www.derkeiler.com/Mailing-Lists/securityfocus/security-basics/2001-12/0345.html
Basically it explains that if you press CTRL-Q, you will see your commands, and their output again. Problem solved. This one had bugged me a few times over the years, and I had just disconnected from the server, and reconnected moments later to fix the problem.
http://www.derkeiler.com/Mailing-Lists/securityfocus/security-basics/2001-12/0345.html
Basically it explains that if you press CTRL-Q, you will see your commands, and their output again. Problem solved. This one had bugged me a few times over the years, and I had just disconnected from the server, and reconnected moments later to fix the problem.
Sunday, April 1, 2007
what sent me on my search of rpmbuild in the first place
I found myself trying to use cfdisk on the fedora core 5 (fc5) system, only to find that it didn't exist and there were no precompiled packages for it that I could see. I did some searching, finding out that cfdisk comes with the util-linux package (on a NORMAL system ;p) ... however, it was nowhere to be found in the fc5 util-linux package. I searched google for some answers and found that the redhat team had removed cfdisk from the build of util-linux because it 'sucked' back in 2001. I personally find cfdisk handy for both editing and viewing partitions. I continued on to get the util-linux source package and then tried to rebuild it, finding the system was missing rpmbuild by default (probably because I didn't install the development options during the installation).
I after the whole problem of finding rpmbuild missing and not in the package I expected, I got that sorted out, and continued on to try and rebuild util-linux with cfdisk included.
// note: first here's a few other steps I took before getting to the rebuild part
// to get the yumdownloader program
yum install yum-utils
// to get the util-linux source package from the repositories
yumdownloader --source util-linux --enablerepo core-source --enablerepo extras-source --enablerepo updates-source
// and finally, editing the spec file and trying to build the source package
cd /usr/src/redhat/SPECS
nano -wb util-linux.spec
// find any spots that remove cfdisk functionality (hint: CTRL-W for search in nano, and put in cfdisk and then remove those references to cfdisk, README.cfdisk and one other one I don't recall what)
// I then proceeded with my first attempt to rebuild the package (while in the SPECS dir still):
// -bb just builds the binary pacakge, as we don't really need a modified version of the source package
rpmbuild -bb util-linux.spec
error: Failed build dependencies: pam-devel is needed by util-linux-2.13-0.20.4.i386 ncurses-devel is needed by util-linux-2.13-0.20.4.i386 libtermcap-devel is needed by util-linux-2.13-0.20.4.i386 zlib-devel is needed by util-linux-2.13-0.20.4.i386 slang-devel is needed by util-linux-2.13-0.20.4.i386 texinfo is needed by util-linux-2.13-0.20.4.i386 gettext-devel is needed by util-linux-2.13-0.20.4.i386 libselinux-devel is needed by util-linux-2.13-0.20.4.i386 e2fsprogs-devel >= 1.36 is needed by util-linux-2.13-0.20.4.i386 audit-libs-devel >= 1.0.6 is needed by util-linux-2.13-0.20.4.i386
// followed by: (to fix the problems, which also installed other dependencies)
yum install pam-devel ncurses-devel libtermcap-devel zlib-devel slang-devel texinfo gettext-devel libselinux-devel e2fsprogs-devel audit-libs-devel
// and yet again, followed by (because of a build error saying it couldn't find aclocal, which also installed m4 as a dependency):
yum install automake autoconf
// I then re-ran rpmbuild -bb --target=i586 util-linux.spec
// with the following results:
Obsoletes: fdisk tunelp mount losetup schedutils
Checking for unpackaged file(s): /usr/lib/rpm/check-files /var/tmp/util-linux-root
error: Installed (but unpackaged) file(s) found:
/sbin/cfdisk
/usr/share/man/man8/cfdisk.8.gz
RPM build errors:
Installed (but unpackaged) file(s) found:
/sbin/cfdisk
/usr/share/man/man8/cfdisk.8.gz
// This means that the cfdisk file was built, but isn't listed as an included file in the rpm package (per the spec file) ... so I need to edit the util-linux.spec file to be like the following:
// old:
/sbin/fdisk
%{_mandir}/man8/fdisk.8*
// new:
/sbin/fdisk
%{_mandir}/man8/fdisk.8*
/sbin/cfdisk
%{_mandir}/man8/cfdisk.8*
// Finally... a successful build of util-linux with cfdisk being included in the package instead of behing removed.
// and finally, the commands to install this util-linux over top your old util linux:
rpm -Uvh --force /usr/src/redhat/RPMS/i586/util-linux-2.13-0.20.4.i586.rpm
// --force was required since the package was already listed as being installed (and technically it was the same version)
// one thing to note is that if redhat ever updates the util-linux package, it may over-write your util-linux package during the update... I'm not sure if it will remove the cfdisk binary or not (it probably will), so you may want to add util-linux to a list of packages that are not to be updated automatically... or, if you're energetic, you could create a small patch between the original spec file and the modified one and keep it around for when you want to rebuild util-linux with newer source packages. The second idea may be better in the long run, as there may be security updates that should be installed for this package at some point.. so of course to err on the side of safety, you should allow redhat to replace the util-linux package with the default ones (if there are updates) and if you ever notice cfdisk is not available on the box, it means you need to go download the latest source package for util-linux from the repositories, edit the specfile, and build away, and finally re-install the updated package.
I after the whole problem of finding rpmbuild missing and not in the package I expected, I got that sorted out, and continued on to try and rebuild util-linux with cfdisk included.
// note: first here's a few other steps I took before getting to the rebuild part
// to get the yumdownloader program
yum install yum-utils
// to get the util-linux source package from the repositories
yumdownloader --source util-linux --enablerepo core-source --enablerepo extras-source --enablerepo updates-source
// and finally, editing the spec file and trying to build the source package
cd /usr/src/redhat/SPECS
nano -wb util-linux.spec
// find any spots that remove cfdisk functionality (hint: CTRL-W for search in nano, and put in cfdisk and then remove those references to cfdisk, README.cfdisk and one other one I don't recall what)
// I then proceeded with my first attempt to rebuild the package (while in the SPECS dir still):
// -bb just builds the binary pacakge, as we don't really need a modified version of the source package
rpmbuild -bb util-linux.spec
error: Failed build dependencies: pam-devel is needed by util-linux-2.13-0.20.4.i386 ncurses-devel is needed by util-linux-2.13-0.20.4.i386 libtermcap-devel is needed by util-linux-2.13-0.20.4.i386 zlib-devel is needed by util-linux-2.13-0.20.4.i386 slang-devel is needed by util-linux-2.13-0.20.4.i386 texinfo is needed by util-linux-2.13-0.20.4.i386 gettext-devel is needed by util-linux-2.13-0.20.4.i386 libselinux-devel is needed by util-linux-2.13-0.20.4.i386 e2fsprogs-devel >= 1.36 is needed by util-linux-2.13-0.20.4.i386 audit-libs-devel >= 1.0.6 is needed by util-linux-2.13-0.20.4.i386
// followed by: (to fix the problems, which also installed other dependencies)
yum install pam-devel ncurses-devel libtermcap-devel zlib-devel slang-devel texinfo gettext-devel libselinux-devel e2fsprogs-devel audit-libs-devel
// and yet again, followed by (because of a build error saying it couldn't find aclocal, which also installed m4 as a dependency):
yum install automake autoconf
// I then re-ran rpmbuild -bb --target=i586 util-linux.spec
// with the following results:
Obsoletes: fdisk tunelp mount losetup schedutils
Checking for unpackaged file(s): /usr/lib/rpm/check-files /var/tmp/util-linux-root
error: Installed (but unpackaged) file(s) found:
/sbin/cfdisk
/usr/share/man/man8/cfdisk.8.gz
RPM build errors:
Installed (but unpackaged) file(s) found:
/sbin/cfdisk
/usr/share/man/man8/cfdisk.8.gz
// This means that the cfdisk file was built, but isn't listed as an included file in the rpm package (per the spec file) ... so I need to edit the util-linux.spec file to be like the following:
// old:
/sbin/fdisk
%{_mandir}/man8/fdisk.8*
// new:
/sbin/fdisk
%{_mandir}/man8/fdisk.8*
/sbin/cfdisk
%{_mandir}/man8/cfdisk.8*
// Finally... a successful build of util-linux with cfdisk being included in the package instead of behing removed.
// and finally, the commands to install this util-linux over top your old util linux:
rpm -Uvh --force /usr/src/redhat/RPMS/i586/util-linux-2.13-0.20.4.i586.rpm
// --force was required since the package was already listed as being installed (and technically it was the same version)
// one thing to note is that if redhat ever updates the util-linux package, it may over-write your util-linux package during the update... I'm not sure if it will remove the cfdisk binary or not (it probably will), so you may want to add util-linux to a list of packages that are not to be updated automatically... or, if you're energetic, you could create a small patch between the original spec file and the modified one and keep it around for when you want to rebuild util-linux with newer source packages. The second idea may be better in the long run, as there may be security updates that should be installed for this package at some point.. so of course to err on the side of safety, you should allow redhat to replace the util-linux package with the default ones (if there are updates) and if you ever notice cfdisk is not available on the box, it means you need to go download the latest source package for util-linux from the repositories, edit the specfile, and build away, and finally re-install the updated package.
Labels:
5,
cfdisk,
core,
fc5,
fedora,
missing,
redhat,
rpmbuild,
util-linux,
yum,
yum-utils,
yumdownloader
linux fedora fc5 missing rpmbuild OR can't find rpmbuild OR no rpmbuild
I was using a fedora core 5 (fc5) box today and ran into a problem with not being able to build any packages from source. I found that rpmbuild was not installed, and a cursory search showed that rpmbuild comes with the rpm package (as expected) ; however, while rpm was installed on this system (by default of course), there was no rpmbuild executable (or symlink) to be found.
Rpmbuild is usually found as /usr/bin/rpmbuild and on one box I checked, was a symlink to /usr/lib/rpm/rpmb. On the other (SuSE 10.1) box that had rpmbuild, I checked which package owned this file/symlink with the following result:
susemachine:~ # rpm -q --whatprovides /usr/bin/rpmbuild
rpm-4.4.2-43.4
After a couple minutes of googling and not finding much, I finally stumbled across a post that had the word rpm-build in it... this sent me on some cursory searches with the new keyword. I eventually found enough information showing that fedora provided rpmbuild in the rpm-build package instead of the rpm package.
To finally fix the problem, I installed the rpm-build package using the following command (note: 'yum update rpm-build' failed to do anything, since rpm-build wasn't already installed):
yum install rpm-build
This fixed the missing rpmbuild problem and shows the following:
[root@localhost ~]# rpm -q --whatprovides /usr/bin/rpmbuild
rpm-build-4.4.2-15.2
So there's another quirk between redhat fedora (I believe older redhat 8/9 releases provided rpmbuild in the rpm package.. but I did not verify this) and SuSE.
While trying to come up with a reason as to why they split it out from the rpm package, I could only come up with the fact that not all machines need package rebuild capabilities and in turn, they save a few bytes of space by not installing these pieces of the rpm system.
Rpmbuild is usually found as /usr/bin/rpmbuild and on one box I checked, was a symlink to /usr/lib/rpm/rpmb. On the other (SuSE 10.1) box that had rpmbuild, I checked which package owned this file/symlink with the following result:
susemachine:~ # rpm -q --whatprovides /usr/bin/rpmbuild
rpm-4.4.2-43.4
After a couple minutes of googling and not finding much, I finally stumbled across a post that had the word rpm-build in it... this sent me on some cursory searches with the new keyword. I eventually found enough information showing that fedora provided rpmbuild in the rpm-build package instead of the rpm package.
To finally fix the problem, I installed the rpm-build package using the following command (note: 'yum update rpm-build' failed to do anything, since rpm-build wasn't already installed):
yum install rpm-build
This fixed the missing rpmbuild problem and shows the following:
[root@localhost ~]# rpm -q --whatprovides /usr/bin/rpmbuild
rpm-build-4.4.2-15.2
So there's another quirk between redhat fedora (I believe older redhat 8/9 releases provided rpmbuild in the rpm package.. but I did not verify this) and SuSE.
While trying to come up with a reason as to why they split it out from the rpm package, I could only come up with the fact that not all machines need package rebuild capabilities and in turn, they save a few bytes of space by not installing these pieces of the rpm system.
Subscribe to:
Posts (Atom)