Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 22 Oct 1999 14:59:09 -0700 (PDT)
From:      Jeff Gray <jwg@netbox.com>
To:        Questions at FreeBSD <freebsd-questions@freebsd.org>
Subject:   Re: newbie kernel question- strip problem
Message-ID:  <Pine.BSF.4.10.9910221450060.4527-100000@cm-24-142-61-16.cableco-op.ispchannel.com>

next in thread | raw e-mail | index | archive | help
So, I tried it but.....does not appear to work.

Running 3.3 Release

# pwd
/
# strip -g --strip-debug kernel
/usr/libexec/elf/strip: kernel: rename: Operation not permitted 


permissions are, 
-r-xr-xr-x   1 root  wheel  10691754 Oct 21 10:19 kernel

So, I tried, in preparation, 
# chmod 755 kernel
chmod: kernel: Operation not permitted  

I then made a copy of the kernel in a /usr directory and ran the same 
strip -g --strip-debug /usr/play/kernel.debut

Worked perfectly, took only a couple of seconds. Went from 10MB to 2 MB

Rename the one from the play directory as kernel?  Not very comfortable
until understanding why the general instruction failled.

Thanks
jeff



> 
> You probably have a debug kernel with symbols built into it. I think you
> can "strip -g kernel" but it has been a while.

Have never tried this so I wish to be a bit careful.

Looking at man strip and the archives, for ELF kernels
 cd / 
 strip -g --strip-debug kernel

Nothing else required, this will reduce the size of the object file
/kernel

This is a real good thing if it is safe, for those with / partitions that
are too small.

Safe?  Any other steps?

Thanks
jeff





To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.10.9910221450060.4527-100000>