Problem snmpd on cacti server

Hello master,

I have a case, initially cacti and snmpd running well.

Then I want to install the nano editor with the command:
Code:
# pkg install nano

But the Pkg is also upgraded.

root@mrtg:~ # pkg install nano
Updating repository catalogue
digests.txz                                                                               100% 2733KB  48.8KB/s  62.7KB/s   00:56
packagesite.txz                                                                           100% 6600KB 101.5KB/s 240.5KB/s   01:05
Incremental update completed, 32534 packages processed:
0 packages updated, 0 removed and 32534 added.
New version of pkg detected; it needs to be installed first.
The following 1 packages will be installed:

        Upgrading pkg: 1.2.7_3 -> 1.10.5_3

The installation will require 3 MB more space

3 MB to be downloaded

Proceed with installing packages [y/N]: y
pkg-1.10.5_3.txz                                                                          100% 2607KB  89.9KB/s  67.3KB/s   00:29
Checking integrity... done
[1/1] Upgrading pkg from 1.2.7_3 to 1.10.5_3... done
/lib/libc.so.7: version FBSD_1.4 required by /usr/local/lib/libpkg.so.4 not found
And after i check, snmpd error while i'm restart :
Code:
root@mrtg:~ # service snmpd start
Starting snmpd.
Shared object "libpkg.so.1" not found, required by "snmpd"
/usr/local/etc/rc.d/snmpd: WARNING: failed to start snmpd
Then, i symlink libpkg.so.1 on direktory /usr/local/lib, new errors appears :
Code:
root@mrtg:~ # service snmpd restart
snmpd not running? (check /var/run/net_snmpd.pid).
Starting snmpd.
/usr/local/lib/libpkg.so.1: version LIBPKG_1.2 required by /usr/local/lib/libnetsnmpmibs.so.30 not found
/usr/local/etc/rc.d/snmpd: WARNING: failed to start snmpd
Anyone can help ?
please urgent :((((((


Best Regards,
Arsyam
 
/lib/libc.so.7: version FBSD_1.4 required by /usr/local/lib/libpkg.so.4 not found
What version of FreeBSD?

Keep your system updated. It looks like you haven't updated in about 5 years. You really need to be more vigilant in this regard.

Then, I symlink libpkg.so.1 on direktory /usr/local/lib
Never, ever, do this. It's never the correct solution.
 
Dear SirDice,

This my FreeBSD version :
Code:
root@mrtg:~ # freebsd-version
10.0-RELEASE
So what should I do? I am newbie :(

Best Regards,
Arsyam
 
Dear SirDice,

Can I return or undo pkg 1.10.5_3 to 1.2.7_3?

because cacti is needed in my place of work. :(

Best Regards,
Arsyam
 
The old package may still be lingering in /var/cache/pkg. But I would put some effort into correctly updating the machine. Besides being End of Life you're also missing about 5 years worth of security updates making the machine a serious liability on your network,
 
Dear SirDice,

If i want to updating this machine, please give me step by step so that cacti and snmpd running well.

Please help me sir :(


Best Regards,
 
Dear SirDice,

If I update FreeBSD, will it affect cacti and snmpd (data cacti/ rra) ?

Best Regards,
 
It shouldn't. But it's always a good idea to have a backup of course, just in case.
 
Dear SirDice,

If now the version I use is 10.0, then what version should I update to freeBSD?

Best Regards,
Arsyam
 
In your case I'd go with 10.4 for now. Once that's done you should plan an upgrade to 11.x.
 
Dear SirDice,

I have run the following command:

# freebsd-update -r 10.4-RELEASE upgrade

And the result is like this (attached)

So what should i do ?

Run this command :
# nextboot -k GENERIC

Or run this command :
# shutdown -r now

# freebsd-update install
???

Please help me Sir.


Best Regards,
Arsyam
 

Attachments

  • Screenshot_2.jpg
    Screenshot_2.jpg
    53.8 KB · Views: 171
Dear SirDice,


I have updated, but when I check the freebsd-version is still 10.0-RELEASE.

Why?


Best Regards,
 
Installation is done with freebsd-update install. A freebsd-update ..... upgrade only downloads the updates.
 
Installation is done with freebsd-update install. A freebsd-update ..... upgrade only downloads the updates.

Dear Sir SirDice

I have a problem.

My FreeBSD Version is 10.0-RELEASE, and i upgrade use this command :

# freebsd-update -r 10.4-RELEASE upgrade

# shutdown -r now

#freebsd-update install

And this is output :

segmentation fault (core dumped)
segmentation fault (core dumped)
segmentation fault (core dumped)


I can't stop that output and then im restart the VM.

and i get the error (attached).

I was run this command :

enter full pathname of shell or return for /bin/sh : /rescue/sh
# fsck -y
# mount -a
# mount -a -t ufs
# fsck /


but still cannot booting :(

Please help me Sir :(


Best Regards,
 

Attachments

  • Screenshot_4.jpg
    Screenshot_4.jpg
    107 KB · Views: 166
I'm wondering why you're getting an "exec format" error. I've only seen that happen when I messed up with 32 vs 64 bit. But a freebsd-update(8) always downloads the correct one so this shouldn't happen.

For now try to put back your old kernel:
Code:
cp -R /boot/kernel.old /boot/kernel
And boot that. Then post the whole output from uname -a.
 
I'm wondering why you're getting an "exec format" error. I've only seen that happen when I messed up with 32 vs 64 bit. But a freebsd-update(8) always downloads the correct one so this shouldn't happen.

For now try to put back your old kernel:
Code:
cp -R /boot/kernel.old /boot/kernel
And boot that. Then post the whole output from uname -a.

Dear Mr. SirDice

I'am sorry late reply.

Thanks for your answer.

I have done what you suggested.

Attached is the result of the command I have done (attached).

Please help.


Best Regards,
 

Attachments

  • Screenshot_9.jpg
    Screenshot_9.jpg
    32 KB · Views: 167
I'm wondering why you're getting an "exec format" error. I've only seen that happen when I messed up with 32 vs 64 bit. But a freebsd-update(8) always downloads the correct one so this shouldn't happen.

For now try to put back your old kernel:
Code:
cp -R /boot/kernel.old /boot/kernel
And boot that. Then post the whole output from uname -a.

Dear Sir SirDice ,

Please help me Sir.


Best Regards,
 
Just copying the kernel doesn't make it active. So you'll need to reboot, that will boot your old kernel again.
 
Just copying the kernel doesn't make it active. So you'll need to reboot, that will boot your old kernel again.

Dear SirDice

Yes, I have copied the kernel, and rebooted.
But it's still an error.

Please help me solve this problem. :(



Best Regards,
 

Attachments

  • Screenshot_4.png
    Screenshot_4.png
    116.8 KB · Views: 187
  • Screenshot_5.png
    Screenshot_5.png
    124.5 KB · Views: 174
And you didn't notice the read-only errors? You actually didn't copy anything.

Dear SirDice ,

Yes,
I see a read-only error, but after I run the mount -a command, I can copy /boot/kernel.old to /boot/kernel.

# mv /boot/kernel /boot/kernel-backup
# cp -R /boot/kernel.old /boot/kernel

Regards,
 

Attachments

  • Screenshot_17.jpg
    Screenshot_17.jpg
    47.2 KB · Views: 193
Back
Top