# [solved]How can I add 'modprobe XXX' to rc-update??

## leiking

Here is the thing:

When I emerged Virtualbox, and ran it, It shows:

```

WARNING: The VirtualBox kernel modules are not loaded.

         Please load all the needed kernel modules by:

           for m in vbox{drv,netadp,netflt}; do modprobe $m; done

         You will not be able to start VMs until this problem is fixed.

```

I want the cmd 

```

for m in vbox{drv,netadp,netflt}; do modprobe $m; done

```

ran at system startup, Any method ????

Thanks!!![/code]Last edited by leiking on Thu Jun 14, 2012 2:09 am; edited 1 time in total

----------

## xaviermiller

add those modules in /etc/conf.d/modules

----------

## leiking

 *XavierMiller wrote:*   

> add those modules in /etc/conf.d/modules

 

I add this line to the file

```

modules="vboxdrv vboxnetadp vboxnetflt"

```

In the rc-setup step,  The system hanged and can not countinue. It shows 'loading module vbox'

 BTW, how can I skip some rc-setup cmd?? I use the rescue disk when system failed, It is boring!!!!!!

Thanks, @Xavier

----------

## Logicien

Did you emerge the virtualbox-modules package? You have to emerge this package for each running kernel for the modules vboxdrv vboxnetadp vboxnetflt be load at boot time.

----------

## leiking

 *Logicien wrote:*   

> Did you emerge the virtualbox-modules package? You have to emerge this package for each running kernel for the modules vboxdrv vboxnetadp vboxnetflt be load at boot time.

 

I have installed, But it cannot work....

```

[I] app-emulation/virtualbox-modules (4.1.8@03/05/2012): Kernel Modules for Virtualbox

```

----------

## sebB

Are you in the vboxusers group?

What does modprobe vboxdrv say?

----------

## krinn

 *leiking wrote:*   

> 
> 
> In the rc-setup step,  The system hanged and can not countinue. It shows 'loading module vbox'
> 
>  BTW, how can I skip some rc-setup cmd?? I use the rescue disk when system failed, It is boring!!!!!!
> ...

 

You can use tow different kernel versions, add them to grub and adding support for your "trouble" module by specifying your kernel version

This is just switching /etc/conf.d/modules to

modules_2_6_38="vboxdrv vboxnetadp vboxnetflt"

now if you boot a 2.6.38 kernel : modules will be loaded, if they stuck you, reboot and boot any kernel that is not 2.6.38 to avoid the module loading part.

----------

## Kaso_da_Zmok

 *Quote:*   

> BTW, how can I skip some rc-setup cmd?? I use the rescue disk when system failed, It is boring!!!!!! 

 

```
/etc/rc.conf 
```

```
# Set rc_interactive to "YES" and you'll be able to press the I key during

# boot so you can choose to start specific services. Set to "NO" to disable

# this feature. This feature is automatically disabled if rc_parallel is

# set to YES.

#rc_interactive="YES"
```

----------

## leiking

 *krinn wrote:*   

>  *leiking wrote:*   
> 
> In the rc-setup step,  The system hanged and can not countinue. It shows 'loading module vbox'
> 
>  BTW, how can I skip some rc-setup cmd?? I use the rescue disk when system failed, It is boring!!!!!!
> ...

 

Right answer. thanks.

----------

