# Upgrade FreeBSD 9.2 to 10 - RELEASE by freebsd-update



## bryn1u (Jan 21, 2014)

Hey,

I'm trying upgrade my FreeBSD server from 9.2 to 10.0-RELEASE but when I run command `freebsd-update upgrade -r 10.0-RELEASE` I got some error:

```
root@ks3360102:~ # freebsd-update upgrade -r 10.0-RELEASE
Looking up update.FreeBSD.org mirrors... 5 mirrors found.
Fetching metadata signature for 9.2-RELEASE from update2.freebsd.org... done.
Fetching metadata index... done.
Fetching 1 metadata files... failed.
root@ks3360102:~ #
```

I did that before and everything was ok. What's wrong?

Greetz,
Michał


----------



## ankscorek (Jan 21, 2014)

Hello friends.

I am trying an upgrade from 9.1 to 10.0.


```
freebsd-update upgrade -r 10.0-RELEASE
Looking up update.FreeBSD.org mirrors... 5 mirrors found.
Fetching metadata signature for 9.1-RELEASE from update6.freebsd.org... done.
Fetching metadata index... done.
Inspecting system... done.

The following components of FreeBSD seem to be installed:
kernel/generic src/src world/base

The following components of FreeBSD do not seem to be installed:
world/doc world/games

Does this look reasonable (y/n)? y

Fetching metadata signature for 10.0-RELEASE from update6.freebsd.org... done.
Fetching metadata index... done.

The update metadata is correctly signed, but
failed an integrity check.
Cowardly refusing to proceed any further.
```

I also tried 

```
sed -i '' -e 's/=_/=%@_/' /usr/sbin/freebsd-update
```

I also tried to change the env to


```
# setenv PACKAGESITE ftp://ftp.freebsd.org/pub/FreeBSD/releases/i386/10.0-RELEASE/
```

Still I am having the first error. please someone guide me.


----------



## Juanitou (Jan 21, 2014)

Have you fully updated your systems (`freebsd-update fetch install`) before trying to upgrade them? There are two errata notices mentioned in the 10.0-RELEASE announcement concerning freebsd-update.


----------



## ankscorek (Jan 21, 2014)

The system is up to date as this is what I get after doing fetch and install



> Installing updates... done.


----------



## bryn1u (Jan 21, 2014)

Juanitou said:
			
		

> Have you fully updated your systems (`freebsd-update fetch install`) before trying to upgrade them? There are two errata notices mentioned in the 10.0-RELEASE announcement concerning freebsd-update.



Ehh. Of course you're right. Works perfectly


----------



## ankscorek (Jan 22, 2014)

Thank you @jyunatou and @bryn1u.

After

```
freebsd-update fetch install
```

I followed the normal procedure and i was able to upgrade to 10.0. This was followed by `pkg update`, reboot and again`freebsd-update install`.

Presently, re0 is down by default. I have to use


```
service netif restart
service routing restart
```

to connect to the internet.

Lastly it shows starting slim, but i am unable to get the graphical login screen. I did the last command of `freebsd-update install`  to remove the old libraries on the command prompt.

Please any suggestions.


----------



## nanotek (Jan 22, 2014)

ankscorek said:
			
		

> i followed the normal procedure and i was able to upgrade to 10.0. This was followed by pkg update, reboot and again freebsd-update install
> 
> [...]
> 
> PLease any suggestions



`pkg upgrade` instead of `pkg update` maybe.


----------



## ankscorek (Jan 22, 2014)

Ok I am sorry the command used was:

`pkg upgrade`

I tried to 

`$startxfce4`

I got the error message

```
unable to locate shared object libcrypto.so.6 needed to start X
```

I tried to deinstall and install xorg but I got the error


```
does not know how to make install xorg
```

Please point me in correct direction.


----------



## cbrace (Jan 22, 2014)

I trying to upgrade a v9.0 system and I keep getting that same error message, even after running that `sed` patch and of course the `fetch` command etc. Not sure what to try next.


----------



## SirDice (Jan 22, 2014)

@ankscorek, some of your packages are still from 9.x. A `pkg upgrade` only upgrades packages that happen to be out of date. You need to reinstall _all_ packages. A `pkg upgrade -f` should do the trick. 

@cbrace, what error message?


----------



## ItsNannerpuss (Jan 23, 2014)

Edit: Found my issue, freebsd-update working now.


----------



## ankscorek (Jan 23, 2014)

> some of your packages are still from 9.x. A pkg upgrade only upgrades packages that happen to be out of date. You need to reinstall all packages. A pkg upgrade -f should do the trick.



I tried this but I got an error.


```
pkg cannot error as it cannot locate libarchive.so.5
```

I tried running `portmaster -af`. This also failed.

*A*ny suggestions please.


----------



## dpejesh (Jan 23, 2014)

`pkg-static upgrade -f` is what you want in this situation.


----------



## ankscorek (Jan 23, 2014)

> pkg-static upgrade -f is what you want in this situation.



I tried this but the error received was

Error while trying to install/upgrade packages, as there are unmet dependencies

Any suggestions please.

PLease do i need to do a fresh install?


----------



## cbrace (Jan 25, 2014)

SirDice said:
			
		

> @ankscorek@cbrace, what error message?




```
# freebsd-update upgrade -r 10.0-RELEASE
Looking up update.FreeBSD.org mirrors... 5 mirrors found.
Fetching metadata signature for 9.0-RELEASE from update2.freebsd.org... done.
Fetching metadata index... done.
Inspecting system... done.

WARNING: This system is running a "venus" kernel, which is not a
kernel configuration distributed as part of FreeBSD 9.0-RELEASE.
This kernel will not be updated: you MUST update the kernel manually
before running "/usr/sbin/freebsd-update install".

The following components of FreeBSD seem to be installed:
src/src world/base world/doc

The following components of FreeBSD do not seem to be installed:
kernel/generic world/games world/lib32

Does this look reasonable (y/n)? y

Fetching metadata signature for 10.0-RELEASE from update2.freebsd.org... done.
Fetching metadata index... done.

The update metadata is correctly signed, but
failed an integrity check.
Cowardly refusing to proceed any further.
```
This system is currently at 9.0-RELEASE.


----------



## ankscorek (Jan 25, 2014)

@cbrace

Please scroll up you will be able to upgrade but then you will face the problem where I am stuck.

The command

```
pkg-static upgrade -f
```

downloads utility but then later it shows lots of conflicts and then the system again is stuck asking for the library files. At least I am not getting unmet dependencies error.

Main conflict it is showing with perl5. I am unable to remove it using any command. pkg-static install xorg tells me that xorg is already installed.

startx tells me unable to locate libcrypto.so.6

This problem started after the last usage of command which is 

```
freebsd-update install
```
prior to this I was getting X working properly
any suggestions please.


----------



## ankscorek (Jan 28, 2014)

The solution is here

http://forums.freebsd.org/viewtopic.php?f=5&t=44500


----------



## MatiasColli (Jun 7, 2014)

The problem lies in a broken version of freebsd-update(8) which got fixed in FreeBSD 9.0-RC1. To fix your version simply run the following command:
`# sed -i '' -e 's/=_/=%@_/' /usr/sbin/freebsd-update`

Matias Colli
UNIX Administrator


----------

