Slackware This Forum is for the discussion of Slackware Linux.
|
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
|
11-12-2013, 08:22 PM
|
#1
|
Member
Registered: Sep 2001
Location: Texas :(
Distribution: Slackware64- 5.15.2
Posts: 909
Rep:
|
Kernel Recompile - for 13.37 - cp: target '.config' is not a directory
So far this is what I did - hopefully nothing, wrong.
Code:
root@machine:/usr/src/linux# make mrproper
root@machine:/usr/src/linux# cp /boot/config-generic-smp-2.6.37.6-smp-$(uname -r) /usr/src/linux/.config
cp: target '/usr/src/linux/.config' is not a directory
Is it a syntax error? Should the cp to, be: /usr/src/linux/ ?
I don't want to do anything i can't back out off.
I'm running 13.37 32bit Xfce on Leveno T500 laptop with the Huge.smp I want to rebuild or recompile 2.6.37 using the source that was in /usr/src/linux & config-gerneric-smp-2.6.37.6-smp in /boot. Following
Slackware Linux in 10 easy steps:
http://blog.tpa.me.uk/slackware-kern...guide/#respond It seems so simple. I did this once before but forgot about it.
While referring to AlienBob's wiki:
http://alien.slackbook.org/dokuwiki/...kernelbuilding
As well as, Post on this forum: Kernel Compile Guide for 2.6.0
Thank you for your time & effort it is appreciated.
Last edited by NightSky; 11-12-2013 at 09:08 PM.
Reason: Tired typo
|
|
|
11-12-2013, 08:27 PM
|
#2
|
Member
Registered: Nov 2003
Posts: 528
Rep: 
|
Not to be too obvious, but the error message says "/ussr/...", although the command has the correct "/usr". Which was it? Because mistyping the directory would result in "is not a directory", I think.
|
|
|
11-12-2013, 09:14 PM
|
#3
|
Member
Registered: Sep 2001
Location: Texas :(
Distribution: Slackware64- 5.15.2
Posts: 909
Original Poster
Rep:
|
lol ... just my transcription. I'm in terminal mode on the laptop as root. The commands were correct. I'm tired by now. Is it too late to bail out for now after:
Code:
root@machine:/usr/src/linux# make mrproper
Thank you
|
|
|
11-12-2013, 09:58 PM
|
#4
|
Moderator
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
|
does nothing else than cleaning up the directory from cruft, it is save to stop here and continue after you got some sleep.
Regarding the command that leads to the error, I would just don't use the uname command, but use Tab-completion instead and look if you still have the problem.
|
|
|
11-12-2013, 10:46 PM
|
#5
|
Member
Registered: Sep 2001
Location: Texas :(
Distribution: Slackware64- 5.15.2
Posts: 909
Original Poster
Rep:
|
@TobiSGD What is Tab-completion? And Supper Thanks
|
|
|
11-12-2013, 11:03 PM
|
#6
|
Moderator
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
|
Quote:
Originally Posted by NightSky
@TobiSGD What is Tab-completion? And Supper Thanks
|
If you press the Tab-key while typing a command or a path in the command-line the shell will try to auto-complete what you type.
For example, in your case you can type and then press the Tab-key, the shell will complete that to If you now continue typing and press Tab again the shell will again try to auto-complete, but in this case it will (on a standard Slackware install) find more than one possible completion. If you repeatedly press Tab the shell will cycle through all possible completions, just do that until you found the correct file and continue typing your command.
For more info look here: https://en.wikipedia.org/wiki/Command_line_completion
Tab completion is one of the reasons why I use Zsh instead of Bash, since Zsh's completion is far superior to Bash's completion.
|
|
1 members found this post helpful.
|
11-14-2013, 03:21 PM
|
#7
|
Member
Registered: Sep 2001
Location: Texas :(
Distribution: Slackware64- 5.15.2
Posts: 909
Original Poster
Rep:
|
Thanks, tobiSGD for explaining & link. Currently reading the following: http://en.linuxreviews.org/Kernel_Rebuild_Guide
Seems that if there was an existing /usr/src/linux/.config file i wiped it out by issuing the: #:make mrproper -command
If such a file did not exist already then the command:
Code:
cp /boot/config-generic-smp-$(uname -r) /usr/src/linux/.config
Is not exactly a usable command but maybe example of what I need to do, which is copy generic-smp.config from /boot to /usr/src/linux.
Fine, I know what $(name -r) does but why insert it before the to path /usr/src/linux? We know the kernel name & version.
Tab Completion is cool, thanks; But its not that kind of syntax puzzle this command line presents.
Read there will be no .config in /usr/src/linux unless something already has been config and saved. Maybe instead of the $(uname -r) option I need to actually plugin the kernel version.
Last edited by NightSky; 11-16-2013 at 12:06 PM.
|
|
|
11-16-2013, 03:10 PM
|
#8
|
Member
Registered: Sep 2001
Location: Texas :(
Distribution: Slackware64- 5.15.2
Posts: 909
Original Poster
Rep:
|
Swaped the above command to:
[/CODE]
#cp /boot/config-generic-smp-2.6.37.6-smp /usr/src/linux/.config
[/CODE] this command copied config-generic-smp over to /usr/src/linux/space .config (Directory)? Or /.config no space (a file)? Can't see the difference even when I look at Alien's tut. Thanks
Last edited by NightSky; 11-16-2013 at 03:12 PM.
|
|
|
11-16-2013, 03:39 PM
|
#9
|
Moderator
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
|
.config has to be a file (and it will be, since the source is a file the copy is also a file) in your kernel-source directory. So, no space.
|
|
1 members found this post helpful.
|
11-16-2013, 05:25 PM
|
#10
|
Member
Registered: Sep 2001
Location: Texas :(
Distribution: Slackware64- 5.15.2
Posts: 909
Original Poster
Rep:
|
@TobiSGD got it  But it won't copy over to /usr/src/linux/.config
Only will copy over if I leave out .config at the end of 'To Path'? This seems right to you?
*Another thing is puzzling me: According to both sysadmin & docuwiki commands are being issued from the /usr/src/linux directory or folder but its actually a symlink to
/usr/src/linux.2.6.37.6 where the source code resides? So commands from the symlink folder uses what is in linux-2.6.37.6 without changing it? This the way it works?
nconfig is the netconfig command and I'm wondering whether to use it or not since the laptop is setup for wireless?
Last edited by NightSky; 11-16-2013 at 05:30 PM.
Reason: ncofig use with wirleless setup?
|
|
|
11-16-2013, 05:41 PM
|
#11
|
Member
Registered: Sep 2006
Location: Earth
Distribution: Slackware 14.1 Slackware64-current multilib
Posts: 278
Rep: 
|
Once you download the new kernel source code .xz package.
mv/cp to /usr/src/ and unzip/package it there(/usr/src), you will have your new kernel source directory.
and then remove the symbolic link of older (linux-version-number), re-links to the new kernel (linux-newer-version#) to linux.
rebuild your new kernel in your new kernel directory not the old, computer is smart, but it can only do what you tell them to do, it can't guess what you might likely to do.
inside of new kenrel directory: make distclean
get official slackware kernel configuration file ( example to build generic-3.10.17 for slackware64 )
Code:
(ftp.slackware.com/pub/slackware/slackware64-current/source/k/config-x86_64/config-generic-3.10.17.x64)
copy this file into new kernel(3.10.17)directory as .config file
make ; make modules_install
get ftp.slackware.com/pub/slackware/slackware64-current/source/k/packaging-x86_64
inside it contains 3 directories, using inside kernel-generic slackbuild scripts to build a slackpkag for installation.
don't forget using kernel-modules's slackbuild script to build kernel-modules of same version.
you need huge package too be on safe side, it for trouble shooting.
DO NOT use upgradepkg to upgrade kernel. Use installpkg
edit your /etc/lilo.conf add your new kernel. keep your old kernel intact, just be safe, testing your new kernel first.
go to /boot; check and make sure links are good.
mkinitrd with your new kernel, add necessary modules into your initrd ram disk.
13.37 version of lilo and mkinitrd don't work with 3.10.17, you need current version source and reompile them with glibc libraries of 13.37
If you using LVM, you might need new version of lvm2 and udev as well
run lilo before your reboot.
good luck
Last edited by number22; 11-16-2013 at 06:27 PM.
|
|
|
11-16-2013, 06:36 PM
|
#12
|
Member
Registered: Sep 2001
Location: Texas :(
Distribution: Slackware64- 5.15.2
Posts: 909
Original Poster
Rep:
|
Thank you number22. I don't want to build new kernel just learning with original installed version. Much later I'll try new one  I'm not so smart.
|
|
|
11-16-2013, 09:39 PM
|
#13
|
Moderator
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
|
Quote:
Originally Posted by NightSky
@TobiSGD got it  But it won't copy over to /usr/src/linux/.config
Only will copy over if I leave out .config at the end of 'To Path'? This seems right to you?
|
No. It does copy the file (you will see that if you use the -v option for cp), but since the filename (.config) begins with a dot it is a hidden file. You can see it with the -a option for ls.
Quote:
*Another thing is puzzling me: According to both sysadmin & docuwiki commands are being issued from the /usr/src/linux directory or folder but its actually a symlink to
/usr/src/linux.2.6.37.6 where the source code resides? So commands from the symlink folder uses what is in linux-2.6.37.6 without changing it? This the way it works?
|
/usr/src/linux is usually a link to the source of the currently installed kernel. If you use the cd command to switch to /usr/src/linux the shell will actually change to the real source path, So any changes you make will be present in the actual directory (here /usr/source/linux-2.6.37).
Quote:
nconfig is the netconfig command and I'm wondering whether to use it or not since the laptop is setup for wireless?
|
Where did you get that nconfig from? I can't find it in the tutorial you linked to.
|
|
1 members found this post helpful.
|
11-16-2013, 11:18 PM
|
#14
|
Member
Registered: Sep 2001
Location: Texas :(
Distribution: Slackware64- 5.15.2
Posts: 909
Original Poster
Rep:
|
@TobiSGD .. thank you so much for explaining all this into one coherent process. We're making progress here
Finally : ls -a shows the .config
nconfig came from man command & research found it in following thread: http://www.linuxquestions.org/questi...estion-911579/ Post #3
Different thread suggests I backup /lib/firmware like this
Code:
mv /lib/firmware /lib/firmware-2.6.36
to make sure I don't lose it. I can do this just from the root command line, don't need to be any special directory? Before I make modules_install.
|
|
|
11-16-2013, 11:31 PM
|
#15
|
Moderator
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
|
Quote:
Originally Posted by NightSky
|
nconfig is in this case not a command, but tells the make command which target in the makefile to run. The nconfig target starts a dialog for changing kernel options in a Norton Commander style, you could also use the menuconfig or xconfig targets. There is indeed one option you should change at least, you should add a custom suffix to the kernel version, so that the original modules will not be overwritten when the new ones are installed. You will find that option in the menu under General setup -> Local version - append to kernel release. For example, I use "-sl" for my kernels, but you can use anything you want.
Quote:
Different thread suggests I backup /lib/firmware like this
Code:
mv /lib/firmware /lib/firmware-2.6.36
to make sure I don't lose it. I can do this just from the root command line, don't need to be any special directory? Before I make modules_install.
|
I never had problems with missing firmware, but of course you can do that, just type it in as is from the command line as root.
|
|
1 members found this post helpful.
|
All times are GMT -5. The time now is 03:48 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|