# /boot/modules/ does not appear



## alie (Nov 26, 2009)

Hmmm,

I just installed FreeBSD 8.0 with zfs and everything seems okay but i cant find /boot/modules on my HDD ... Seems weird for me and i just tried do find / -name "*.ko" but nothing is appears


----------



## DutchDaemon (Nov 26, 2009)

As far as I know, all modules are now under /boot/kernel/, except for some 3rd party ones like nvidia.ko.


----------



## alie (Nov 26, 2009)

Thanks DutchDaemon for ur quick reply

but... i cant find /boot/kernel/ too 

So everytime i want do kldload snd_driver it always failed

Seems weird, is this becoz my zfs config is wrong ?

NOTE: The tutorial tha i used to have zfs root: http://nelsontot.blogspot.com/2009/03/freebsd-installation-and-zfs.html


----------



## DutchDaemon (Nov 26, 2009)

No idea .. but I'm assuming your system _did_ boot somehow, so check `dmesg -a` to find out what's on the Trying to mount root from .. line. That's where a kernel was found, and that's where the modules are likely to be .. or did you mount something *over* /boot by mistake?


----------



## alie (Nov 26, 2009)

@DutchDaemon: My system can boot properly and its running KDE4 now without any problem, the only thing is i cant see my /boot/modules/ or /boot/kernel/

I was wondering, how come my system can load zfs.ko but i cant find it with this command:
# find / -name "zfs.ko"


----------



## SirDice (Nov 26, 2009)

You probably forgot or failed this bit:

```
# rm -rf /tank/boot
# mkdir /tank/bootdir
# cd /tank
# ln -s bootdir/boot boot
```


----------



## knarf (Nov 26, 2009)

alie said:
			
		

> Hmmm,
> 
> I just installed FreeBSD 8.0 with zfs and everything seems okay but i cant find /boot/modules on my HDD ... Seems weird for me and i just tried do find / -name "*.ko" but nothing is appears



First of all, I'd recommend this tutorial for future installations:

http://wiki.freebsd.org/RootOnZFS/GPTZFSBoot

It uses no UFS partition at all. Tried that last night, works fine.

You used the "old" way with booting from ufs, mountroot zfs and then mounting the ufs-partition on /bootdir and a symlink from /boot to /bootdir/boot. Maybe you just forgot to mount it.

This is my fstab:


```
# Device    Mountpoint  FStype  Options      Dump       Pass#
/dev/mirror/root0b none         swap sw      0  0
/dev/mirror/root0a /bootdir     ufs  rw      1  1
/dev/cd0    /cdrom      cd9660  ro,noauto    0  0
md      /tmp       mfs  rw,-s2G  2   0
```


```
% df / /bootdir
Filesystem                1M-blocks   Used  Avail Capacity  Mounted on
root1/root                   314365    124 314241     0%    /
/dev/mirror/root0a             7931   3507   3789    48%    /bootdir
% ls -ld /boot
lrwxr-xr-x  1 root  wheel  12 Jul 14 15:44 /boot@ -> bootdir/boot
```

If this is your problem, make sure to merge the current content of /boot to the ufs partition, not to forget /boot/zfs/zpool.cache.


----------

