kernel compile

ericbsd

Developer
Where can I find the kernels compiled folders once I have done a make buildkernel KERNCONF=GENERIC.
thank you
 
juste know all the system if i do somting like that or buildworl were i can find all file. I work in a project call GhostBSD like PCBSD. But whit gnome I wont make a system like ubuntu with BSD.
 
server# cd /usr/src/sys/${arch}/compile/GENERIC
arch: Undefined variable.
server# cd /usr/src/sys/${arch}/compile/
arch: Undefined variable.
server#
 
server# cd /usr/src/sys/`uname -m`/compile/GENERIC
/usr/src/sys/i386/compile/GENERIC: No such file or directory.
 
server# cd /usr/src/sys
server# ls
Makefile ddb libkern netncp powerpc
amd64 dev modules netsmb rpc
arm fs net nfs security
boot gdb net80211 nfs4client sparc64
bsm geom netatalk nfsclient sun4v
cam gnu netgraph nfsserver sys
cddl i386 netinet nlm tools
compat i4b netinet6 opencrypto ufs
conf ia64 netipsec pc98 vm
contrib isa netipx pccard xdr
crypto kern netnatm pci
server#
 
ericturgeon said:
Where can I find the kernels compiled folders once I have done a make buildkernel KERNCONF=GENERIC.
thank you

Once you do
Code:
make buildkernel KERNCONF=MYKERNEL

you can find the object files in /usr/obj/usr/src/sys/MYKERNEL/

Then, after
Code:
make installkernel KERNCONF=MYKERNEL
as the Handbook says:
The new kernel will be copied to the /boot/kernel directory as /boot/kernel/kernel and the old kernel will be moved to /boot/kernel.old/kernel. Now, shutdown the system and reboot ...
 
Hello!

Please give an advice on the following problem - when building my customized kernel, this operation interrupts because of an error:
MAKE=make sh /usr/src/sys/conf/newvers.sh MARKER
cc -c -O -pipe -std=c99 -g -Wall -Wredundant-decls -Wnested-externs -Wstrict-prototypes -Wmissing-prototypes -Wpointer-arith -Winline -Wcast-qual -Wundef -Wno-pointer-sign -fformat-extensions -nostdinc -I. -I/usr/src/sys -I/usr/src/sys/contrib/altq -D_KERNEL -DHAVE_KERNEL_OPTION_HEADERS -include opt_global.h -fno-common -finline-limit=8000 --param inline-unit-growth=100 --param large-function-growth=1000 -mno-align-long-strings -mpreferred-stack-boundary=2 -mno-mmx -mno-3dnow -mno-sse -mno-sse2 -mno-sse3 -ffreestanding -Werror vers.c
linking kernel.debug
nlm_advlock.o(.text+0x11d8): In function `nlm_advlock_internal':
/usr/src/sys/nlm/nlm_advlock.c:225: undefined reference to `nfs_vinvalbuf'
nlm_advlock.o(.text+0x1273):/usr/src/sys/nlm/nlm_advlock.c:236: undefined reference to `nfs_ticks'
nlm_prot_impl.o(.text+0x2b51): In function `nlm_syscall':
/usr/src/sys/nlm/nlm_prot_impl.c:1543: undefined reference to `nfs_advlock_p'
nlm_prot_impl.o(.text+0x2b57):/usr/src/sys/nlm/nlm_prot_impl.c:1544: undefined reference to `nfs_advlock_p'
nlm_prot_impl.o(.text+0x2b61):/usr/src/sys/nlm/nlm_prot_impl.c:1545: undefined reference to `nfs_reclaim_p'
nlm_prot_impl.o(.text+0x2b67):/usr/src/sys/nlm/nlm_prot_impl.c:1546: undefined reference to `nfs_reclaim_p'
nlm_prot_impl.o(.text+0x2b7f):/usr/src/sys/nlm/nlm_prot_impl.c:1551: undefined reference to `nfs_advlock_p'
nlm_prot_impl.o(.text+0x2b85):/usr/src/sys/nlm/nlm_prot_impl.c:1552: undefined reference to `nfs_reclaim_p'
*** Error code 1

Stop in /usr/obj/usr/src/sys/MARKER.
*** Error code 1

Stop in /usr/src.
*** Error code 1

Stop in /usr/src.

What is wrong? I've done everything according to the Handbook.

My kernel congiguration file is in attachment.
 

Attachments

  • kernel conf.txt
    11.9 KB · Views: 186
You have NFSLOCKD in your kernel. I guess it needs the other NFS options (client and/or server) as well. Either add those, or remove NFSLOCKD.
 
Is it so necessary? It was written in handbook, that this option is for eisa motherboards, mine one isn't of that kind (at least i think so :) ) - that is why i commented that string.

OK, i found smth. When booting with old kernel (working one) my HD was ad0, that's why it says
Trying to mount root from ufs:/dev/ad0s2a
And when booting with customized kernel HD is ad4.
Yes, i tried to type
ufs:ad4s2a
And it seemed to continue loading, but several errors showed up:
No suitable dump device was found
swapon: ad0s2b: No such file or directory
Mounting /etc/fstab dilesystems failed, startup aborted
ERROR: ABORTING BOOT (sending SINGTERM to parent)!
Then the only i can do is to logon from shell.
Can anybody explain me, what's wrong? Why did HD became ad4 instead of ad0 (CD-ROM was and is cd0).
What should i do to make it work?
 
These things happen now and then - it's not completely given which order your IDE channels are numbered in when you start swapping kernels.

When you get to the "mount /etc/fstab failed" etc, you should be able to boot a singleuser shell.
If you do mount -u -w / you'll get write-access to your root partition. You can then use an editor to fix /etc/fstab - I'd suggest mounting /usr so you can use ee or vim or whatever you prefer.

Alternatively, boot with the working kernel, edit the fstab, and reboot to the new kernel.
 
Back
Top