# Fail on MYSQL install



## yagokurt (Aug 29, 2014)

Good morning community, this is my first post on this forum, idk I do not know if it's the right area. I'm having a problem when I try install the MySQL/MariaDB (already tried both). I just bought the dedicated yesterday, format and the unique command I did was


```
portsnap fetch extract
cd /usr/ports/databases/mysql55-server/
make install clean
```

And after the install I got it


```
====> Compressing man pages (compress-man)
===> Staging rc.d startup script(s)
===>  Installing for mysql55-server-5.5.39
===>  Checking if mysql55-server already installed
===>   Registering installation for mysql55-server-5.5.39
===> Creating users and/or groups.
Using existing group 'mysql'.
Using existing user 'mysql'.
Installing mysql55-server-5.5.39... done
************************************************************************

Remember to run mysql_upgrade the first time you start the MySQL server
after an upgrade from an earlier version.

************************************************************************

===> SECURITY REPORT:
      This port has installed the following files which may act as network
      servers and may therefore pose a remote security risk to the system.
/usr/local/libexec/mysqld

      This port has installed the following startup scripts which may cause
      these network services to be started at boot time.
/usr/local/etc/rc.d/mysql-server

      If there are vulnerabilities in these programs there may be a security
      risk to the system. FreeBSD makes no guarantee about the security of
      ports included in the Ports Collection. Please type 'make deinstall'
      to deinstall the port if this is a concern.

      For more information, and contact details about the security
      status of this software, see the following webpage:
http://www.mysql.com/
===>  Cleaning for mysql55-client-5.5.39
===>  Cleaning for mysql55-server-5.5.39
```

And when I try check on `pkg_info` it isn't on the list. And if I try install again it will say MySQL is already installed.


----------



## SirDice (Aug 29, 2014)

What version of FreeBSD?


----------



## yagokurt (Aug 29, 2014)

Right now it*'*s 9.2 but I already tried it with 9.3, and sorry *I* forgot to mention that.


----------



## SirDice (Aug 29, 2014)

Did you install ports-mgmt/pkg and did you add 
	
	



```
WITH_PKGNG=YES
```
 to /etc/make.conf? If that's the case the "old" pkg_* commands do not work any more. Use pkg-info(8) instead.


----------



## yagokurt (Aug 29, 2014)

SirDice said:
			
		

> Did you install ports-mgmt/pkg and did you add
> 
> 
> 
> ...



@SirDice, *I* did not install this first one and my make.conf already have this text. And my `pkg_info` return this, maybe still having the old one

My make.conf:


```
WITH_PKGNG=yes

# added by use.perl 2012-01-18 18:20:28
PERL_VERSION=5.14.1
```

`pkg_info`


```
pkg-info: Command not found.
root@ns3362353:~ # pkg_info
bash-4.1.11         The GNU Project's Bourne Again SHell
compat7x-amd64-7.3.703000.201008_1 A convenience package to install the compat7x
 libraries
cvsup-without-gui-16.1h_4 File distribution system optimized for CVS (non-GUI ve
rsion
dmidecode-2.11      A tool for dumping DMI (SMBIOS) contents in human-readable
fping+ipv6-2.4b2    Quickly ping N hosts w/o flooding the network - IPv6 versio
gettext-0.18.1.1    GNU gettext package
libiconv-1.13.1_1   A character set conversion library
libidn-1.22         Internationalized Domain Names command line tool
libpcap-1.1.1_1     Ubiquitous network traffic capture library
libsmi-0.4.8        A library to access SMI MIB information
lynx-2.8.7.1_1,1    A non-graphical, text-based World-Wide Web client
ncftp-3.2.4         ftp replacement with advanced user interface
ntp-4.2.6p4_2       The Network Time Protocol Distribution
perl-5.14.1_3       Practical Extraction and Report Language
pkg-config-0.25_1   A utility to retrieve information about installed libraries
portmanager-0.4.1_9 FreeBSD installed ports status and safe update utility
rsync-3.0.9         A network file distribution/synchronization utility
screen-4.0.3_13     A multi-screen window manager
smartmontools-5.42_2 S.M.A.R.T. disk monitoring tools
tcpdump-4.1.1       Ubiquitous network traffic analysis tool
vim-lite-7.3.121    Vi "workalike", with many additional features (Lite package
wget-1.13.4_1       Retrieve files from the Net via HTTP(S) and FTP
root@ns3362353:~ #
```


----------



## SirDice (Aug 29, 2014)

You need to run `pkg2ng` to convert the old package registrations. You probably have a mix of old and new package registrations.

And the correct command is `pkg info`, the hyphen is only there so it can have its own man page.


----------



## yagokurt (Aug 29, 2014)

SirDice said:
			
		

> You need to run `pkg2ng` to convert the old package registrations. You probably have a mix of old and new package registrations.
> 
> And the correct command is `pkg info`, the hyphen is only there so it can have its own man page.





Really thanks for your great and fast support, @SirDice, problem solved, MySQL installed. And thanks for the grammar/spelling corrections, i did not know the forum rules and trying to spell without abbreviations *I* saw *I* really need to start spelling right, because *I* had some doubts about how to write some words.


----------



## yagokurt (Aug 29, 2014)

i'm back @SirDice. I'm having a problem on mysql start, after you help me and i check mysql was ok, i decided reinstall the OS to clean all fail try i did, so after mysql install i had a problem with mysql user but i found a topic of you helping a person and it worked for me, but now the mysql didnt start.


```
root@ns3362353:~ # service mysql-server start
Starting mysql.
root@ns3362353:~ # service mysql-server status
mysql is not running.
root@ns3362353:~ #
```

PS: I'm sorry if *I* can*'*t repost it.


[EDIT]


I'm really sorry for it. Already can close the topic and the problem was solved with

```
pwd_mkdb -p /etc/master.passwd
chown -R mysql /var/db/mysql && chgrp -R mysql /var/db/mysql
```


----------

