Error: unable to find the sources of your current Linux

Issues related to applications and software problems
Post Reply
ravi.joshi53
Posts: 3
Joined: 2013/12/27 15:00:54

Error: unable to find the sources of your current Linux

Post by ravi.joshi53 » 2013/12/27 16:02:17

Hi all,

I found my question in various places including here also, but all of them are not working in my case. Please bear with me to read this long post.
I am trying to install VirtualBox 4.3.6 Guest Additions in order to enable folder sharing between my host (Windows 7) and guest (Cent Os 6.3) operating system but It is showing error.

Below is the message displayed while installation was in progress-

Code: Select all

Uncompressing VirtualBox 4.3.6 Guest Additions for Linux............
VirtualBox Guest Additions installer
Removing installed version 4.3.6 of VirtualBox Guest Additions...
Copying additional installer modules ...
Installing additional modules ...
Removing existing VirtualBox non-DKMS kernel modules       [  OK  ]
Building the VirtualBox Guest Additions kernel modules
The headers for the current running kernel were not found. If the following
module compilation fails then this could be the reason.
The missing package can be probably installed with
yum install kernel-devel-2.6.32-279.el6.i686

Building the main Guest Additions module                   [FAILED]
(Look at /var/log/vboxadd-install.log to find out what went wrong)
Doing non-kernel setup of the Guest Additions              [  OK  ]
Installing the Window System drivers
Installing X.Org Server 1.10 modules                       [  OK  ]
Setting up the Window System to use the Guest Additions    [  OK  ]
You may need to restart the hal service and the Window System (or just restart
the guest system) to enable the Guest Additions.

Installing graphics libraries and desktop services componen[  OK  ]
Press Return to close this window...
As per the above message, I tried to install kernel-devel-2.6.32-279.el6.i686 but it went wrong. Below is the message displayed while installing it-

Code: Select all

[root@localhost ~]# yum install kernel-devel-2.6.32-279.el6.i686
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
 * base: centos.aol.in
 * extras: mirror-fpt-telecom.fpt.net
 * updates: mirrors.vonline.vn
Setting up Install Process
No package kernel-devel-2.6.32-279.el6.i686 available.
Error: Nothing to do
[root@localhost ~]# 
Below is the content of /var/log/vboxadd-install.log file-

Code: Select all

/tmp/vbox.0/Makefile.include.header:97: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR=<directory> and run Make again.  Stop.
Creating user for the Guest Additions.
Creating udev rule for the Guest Additions kernel module.
/tmp/vbox.0/Makefile.include.header:97: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR=<directory> and run Make again.  Stop.
Creating user for the Guest Additions.
Creating udev rule for the Guest Additions kernel module.
/tmp/vbox.0/Makefile.include.header:97: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR=<directory> and run Make again.  Stop.
Creating user for the Guest Additions.
Creating udev rule for the Guest Additions kernel module.
/tmp/vbox.0/Makefile.include.header:97: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR=<directory> and run Make again.  Stop.
Creating user for the Guest Additions.
Creating udev rule for the Guest Additions kernel module.
/tmp/vbox.0/Makefile.include.header:97: *** Error: unable to find the sources of your current Linux kernel. Specify KERN_DIR=<directory> and run Make again.  Stop.
Creating user for the Guest Additions.
Creating udev rule for the Guest Additions kernel module.
Below is the more information-

Code: Select all

[root@localhost ~]# cat /etc/issue
CentOS release 6.3 (Final)
Kernel \r on an \m

[root@localhost ~]# uname -r
2.6.32-279.el6.i686
[root@localhost ~]# yum info kernel
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
 * base: centos.aol.in
 * extras: mirrors.digipower.vn
 * updates: mirrors.vonline.vn
Installed Packages
Name        : kernel
Arch        : i686
Version     : 2.6.32
Release     : 279.el6
Size        : 84 M
Repo        : installed
From repo   : anaconda-CentOS-201207051201.i386
Summary     : The Linux kernel
URL         : http://www.kernel.org/
License     : GPLv2
Description : The kernel package contains the Linux kernel (vmlinuz), the core
            : of any Linux operating system.  The kernel handles the basic
            : functions of the operating system: memory allocation, process
            : allocation, device input and output, etc.

Available Packages
Name        : kernel
Arch        : i686
Version     : 2.6.32
Release     : 431.1.2.0.1.el6
Size        : 26 M
Repo        : updates
Summary     : The Linux kernel
URL         : http://www.kernel.org/
License     : GPLv2
Description : The kernel package contains the Linux kernel (vmlinuz), the core
            : of any Linux operating system.  The kernel handles the basic
            : functions of the operating system: memory allocation, process
            : allocation, device input and output, etc.

[root@localhost ~]# yum info kernel-devel
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
 * base: centos.aol.in
 * extras: mirrors.digipower.vn
 * updates: mirrors.vonline.vn
Available Packages
Name        : kernel-devel
Arch        : i686
Version     : 2.6.32
Release     : 431.1.2.0.1.el6
Size        : 8.7 M
Repo        : updates
Summary     : Development package for building kernel modules to match the
            : kernel
URL         : http://www.kernel.org/
License     : GPLv2
Description : This package provides kernel headers and makefiles sufficient to
            : build modules against the kernel package.

[root@localhost ~]# yum info kernel-headers
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
 * base: centos.aol.in
 * extras: mirrors.digipower.vn
 * updates: mirrors.vonline.vn
Installed Packages
Name        : kernel-headers
Arch        : i686
Version     : 2.6.32
Release     : 431.1.2.0.1.el6
Size        : 2.5 M
Repo        : installed
From repo   : updates
Summary     : Header files for the Linux kernel for use by glibc
URL         : http://www.kernel.org/
License     : GPLv2
Description : Kernel-headers includes the C header files that specify the
            : interface between the Linux kernel and userspace libraries and
            : programs.  The header files define structures and constants that
            : are needed for building most standard programs and are also needed
            : for rebuilding the glibc package.

[root@localhost ~]# 
What went wrong? Any suggestions please?

-
Thanks
Ravi

tigalch
QA Team
Posts: 522
Joined: 2012/06/23 17:28:41
Location: Austria

Re: Error: unable to find the sources of your current Linux

Post by tigalch » 2013/12/27 17:00:15

Hello and welcome to the fora,

CentOS 6.3 is deprecated, as 6.5 is the current version. The package you are trying to install is no longer available throught the mirror network, but can be found in vault.centos.org (and if needed downloaded by hand and installed).
But you should run 'yum update' to bring your system up to date. Afterwards installing kernel-devel via yum should work fine. Allthought the openGL module will fail to build on 6.5 (see here), but the rest should work.
New users: take a look at this page

User avatar
toracat
Site Admin
Posts: 7518
Joined: 2006/09/03 16:37:24
Location: California, US
Contact:

Re: Error: unable to find the sources of your current Linux

Post by toracat » 2013/12/27 17:03:10

CentOS 6.3 is obsolete. I strongly suggest you update the system to the current 6.5. If, for some reason, you must stay at 6.3, then you can find older packages at vault.centos.org including kernel-devel.
CentOS Forum FAQ

ravi.joshi53
Posts: 3
Joined: 2013/12/27 15:00:54

Re: Error: unable to find the sources of your current Linux

Post by ravi.joshi53 » 2013/12/27 17:38:12

Hi tigalch and toracat,

Thanks a lot guys for the quick response. Just now I executed "yum update" and found that CentOS is now 6.5 . After this upgrade I restarted it. Now initially it is showing loading screen (horizontal progress bar with CentOS 6.5 written) then a blank screen is coming and it is not going forward from here. :cry:

Please help me to start the upgraded machine.

-
Thanks
Ravi

User avatar
TrevorH
Site Admin
Posts: 33202
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: Error: unable to find the sources of your current Linux

Post by TrevorH » 2013/12/27 17:47:20

Did you reinstall the guest additions? They need to be reinstalled every time you update the kernel.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

ravi.joshi53
Posts: 3
Joined: 2013/12/27 15:00:54

Re: Error: unable to find the sources of your current Linux

Post by ravi.joshi53 » 2013/12/27 18:01:32

Hi TrevorH ,

Oh sorry. I forgot to reinstall guest additions since after updating the machine is showing loading screen (horizontal progress bar with CentOS 6.5 written) then a blank screen is coming and it is not going forward from here. I can't see the login screen. It is impossible to reinstall guest additions without login to machine.

Anyways let me install a fresh CentOS 6.3 and I can download the packages as per your suggested repo. Currently I am out of high speed internet and can't download the latest ISO of CentOs.

Thanks a lot for the quick help.

-
Regards
Ravi

tigalch
QA Team
Posts: 522
Joined: 2012/06/23 17:28:41
Location: Austria

Re: Error: unable to find the sources of your current Linux

Post by tigalch » 2013/12/27 18:17:59

I think no need to reinstall. With 6.4 the xorg api got changed, thus affecting the vbox graphics driver which needs to be rebuild. You should be able to change to a CLI console with pressing Alt+2 (or a higher number just try some). Login through that CLI, mount the vBox additions image (should be in /dev/sr0) and run the VBoxLinuxAdditions.sh. After a restart after that you should be able to see the x desktop again.

TSU2
Posts: 3
Joined: 2013/12/30 21:20:59

Re: Error: unable to find the sources of your current Linux

Post by TSU2 » 2013/12/31 16:28:15

If you install DKMS you shouldn't need to re-build VBox additions after every update.
See the VBox documentation.

HTH,
TSU

tigalch
QA Team
Posts: 522
Joined: 2012/06/23 17:28:41
Location: Austria

Re: Error: unable to find the sources of your current Linux

Post by tigalch » 2014/02/26 19:27:11

Also I'd like to note any error coming from building the openGL module is solved with the release of vBox 4.3.8

Post Reply