How to resolve ld-elf.so.1: /bin/sh: Undefined symbol "stat@FBSD_1.5"

you insult me, I am not a troll and I don't tell you to be here with force, you can go to other section of this forum,
all of my websites is down and now I am so sad and you tell me troll? you don't need to be here and waste your time, I don't have a good feeling with your sentences
by the way, this command give me error message
1.
/rescue/mdconfig /path/to/FreeBSD-12.0-RELEASE-amd64-disc1.iso
my ISO file is not in this path and i cannot find it
/path/to/FreeBSD-12.0-RELEASE-amd64-disc1.iso
6991
 
Ok, have you attached a cdrom on your machine? Have you put the ISO/cd in the cdrom?
if yes, you can mount it:
Code:
/rescue/mount_cd9660 /dev/cd0 /mnt
/rescue/chflags noschg /lib/libc.so.7
/rescue/cp /mnt/lib/libc.so.7 /lib/libc.so.7
 
Ok, have you attached a cdrom on your machine? Have you put the ISO/cd in the cdrom?
if yes, you can mount it:
Code:
/rescue/mount_cd9660 /dev/cd0 /mnt
/rescue/chflags noschg /lib/libc.so.7
/rescue/cp /mnt/lib/libc.so.7 /lib/libc.so.7
thank you 🌹
In the last row I got an error message ( file copied but tell us is Read-only file system )
cp:/lib/libc.so.7: Read-only file system
6993


After that I used your commands In your first post
/usr/sbin/freebsd-update -r 12.0-RELEASE upgrade
/usr/sbin/freebsd-update install
shutdown -r now
/usr/sbin/freebsd-update install

but again I got this error message stat@FBSD_1.5
6994


what is my wrong ?
Of course, I think this error is natural because this command show me about update from source
( I have some of activities like sudo "sh /mnt" but I got an error again )
please tell me what can i do exactly
 
I forgot that single user mode mount the filesystem read only, you'll need to remount it read / write. What is the name of your root partition (/dev/ada0xxx, /dev/da0xxx)? If you don't know, execute the following:
Code:
/rescue/mount
You should see something like: /dev/ufs/rootfs on / (ufs, local, noatime)
Then you can do (replace /dev/ufs/rootfs with the your root partition name):
Code:
/rescue/mount -o rw /dev/ufs/rootfs /
You'll be able to execute the following after:
Code:
/rescue/chflags noschg /lib/libc.so.7
/rescue/cp /mnt/lib/libc.so.7 /lib/libc.so.7
 
EDIT: before doing the following, make sure that you have 12.0-RELEASE in the output of uname -a

With the new libc in place you can drop to multi user (either reboot or type 'exit')
Since your base system is a mix of 11.2 and 12.0 binaries, you'll need to 'overwrite it' with a 12.0 system:
Code:
# backup /etc, just in case
mkdir -p /root/backup_etc
cp -R /etc /root/backup_etc

# remove protection of some binaries
chflags 0 /lib/libthr.so.3 /lib/libcrypt.so.5 /lib/libc.so.7 /libexec/ld-elf.so.1 /sbin/init /usr/bin/passwd /usr/bin/crontab /usr/bin/su /usr/bin/chpass /usr
/bin/login /usr/bin/opieinfo /usr/bin/opiepasswd /usr/lib/librt.so.1

# untar 12.0 world, the FreeBSD install ISO needs to be mounted in /mnt:
tar --exclude etc -xpf /mnt/usr/freebsd-dist/base.txz -C /
 
I forgot that single user mode mount the filesystem read only, you'll need to remount it read / write. What is the name of your root partition (/dev/ada0xxx, /dev/da0xxx)? If you don't know, execute the following:
Code:
/rescue/mount
You should see something like: /dev/ufs/rootfs on / (ufs, local, noatime)
Then you can do (replace /dev/ufs/rootfs with the your root partition name):
Code:
/rescue/mount -o rw /dev/ufs/rootfs /
You'll be able to execute the following after:
Code:
/rescue/chflags noschg /lib/libc.so.7
/rescue/cp /mnt/lib/libc.so.7 /lib/libc.so.7
I got this error message
7013


uname -a
7014



If I knew that update can gotten my time for a long time, never I didn't make it
 
It's useless to execute a command if the previous one did not succeed. Your cdrom is not mounted.
There is another problem: you're still on a 11.2 kernel, updating libc will probably cause more trouble.
You should probably update your kernel first:
Code:
/rescue/mv /boot/kernel /boot/kernel.old
/rescue/tar xpf /mnt/usr/freebsd-dist/kernel.txz -C /
before rebooting make sure the commands suceeded.
You'll be able to update libc/base.txz after that.
 
It's useless to execute a command if the previous one did not succeed. Your cdrom is not mounted.
There is another problem: you're still on a 11.2 kernel, updating libc will probably cause more trouble.
You should probably update your kernel first:
Code:
/rescue/mv /boot/kernel /boot/kernel.old
/rescue/tar xpf /mnt/usr/freebsd-dist/kernel.txz -C /
before rebooting make sure the commands suceeded.
You'll be able to update libc/base.txz after that.
OUTPUT is:
7019
 
Hi all,
I had a similar situation when an upgrade from 11.2 to 12.0 broke and the system became corrupted. I managed to fix it using the instructions on this thread. I am just sharing what I did incase others have similar issues.



Power down the device (at this point I did not have a working shell). Once it gets to the single user prompt do the following:

Code:
/rescue/sh
uname -anr

It reported FreeBSD 12.0 amd64. I then downloaded this OS and mounted it (I was using VM Ware). Then:

Code:
/rescue/mount_cd9660 /dev/cd0 /mnt
/rescue/mount
/rescue/mount -o rw /dev/zroot/ROOT/default /
/rescue/chflags noschg /lib/libc.so.7
/rescue/cp /mnt/lib/libc.so.7 /lib/libc.so.7

exit

At this point I could login to my shell via console. I did "uname -anr" and saw that the system was reporting FreeBSD 12.0. So this was a broken update I was dealing with.

I then run the following steps:

Code:
/rescue/mount_cd9660 /dev/cd0 /mnt
/rescue/ldconfig /lib /usr/lib /usr/local/lib
/rescue/ldconfig -32 /usr/lib32 /usr/local/lib32/compat
cp /mnt/usr/lib/libbz2.so.4 /usr/lib/

I then installed rsync from ports and backed up my files (pkg asked to remove too many packages so went with ports instead). Of course tools like "tar" and "scp" are options but I prefer rsync for network copying. Then:

Code:
freebsd-update fetch
freebsd-update install
shutdown -r

The update worked and all my installed programs were running normally after reboot. I will have to update all packages later but at least the system is ok. For Mysql to work, I had to add this to /etc/rc.conf:

Code:
mysql_limits=""
 
Back
Top