# alq module kldload and kldunload and init 0 causes panic!



## comnetboy (May 11, 2013)

Dear guys;
When we `kldload alq` module after that `kldunload` and after that `init 0`, system gives panic!
We are using FreeBSD 9. Could anybody help in this regard?

Thanks in advance.


----------



## wblock@ (May 11, 2013)

Why are you unloading it?

Use `shutdown -p now` to shut down.


----------



## comnetboy (May 12, 2013)

*alq*

Thanks for reply. I tested `shutdown -p now` and it crashes again. *B*ut I didn't unload it and it didn't crash.


----------



## comnetboy (May 12, 2013)

Dear @wblock@, we have a module, which has 
	
	



```
MODULE_DEPEND(mymodule, alq, 1, 1, 1)
```
 because we are using alq API's in mymodule. When mymodule starts, it loads alq too. we don't unload alq by hand, when mymodule stops and we shutdown FreeBSD, raise the panic.


----------



## wblock@ (May 12, 2013)

Sorry, it's hard to understand.  Is it easier to say that when your custom module has been loaded, the system always panics on shutdown?  The freebsd-hackers mailing list is likely to be a better source for help.


----------



## comnetboy (May 13, 2013)

I think mymodule does not cause panic, because in a fresh FreeBSD 9 or 9.1-RELEASE, if you just type: `kldload alq`, `kldunload alq`, `init 0` or `shutdown -p now`, it will panic! *M*aybe it's a bug.

Our module do*es* the same. *W*hen it comes up, it loads alq. and when it comes down, unloads alq. So after shutdown we have panic.


----------



## SirDice (May 14, 2013)

I suggest filing a problem report.


----------

