Permission denied # rb_sysopen - /tmp/github_api_headers20180618-21004-yrr75i error. - mysql

I am attempting to install mysql using homebrew but I keep getting
Permission denied # rb_sysopen - /tmp/github_api_headers20180618-21004-yrr75i
This is my brew config
HOMEBREW_VERSION: 1.6.9
ORIGIN: https://github.com/Homebrew/brew
HEAD: c814199a791867ab75f90a22715e2475706b13d8
Last commit: 7 hours ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: c58fde35d617490bad4de8faeaa9e9f1c81341ea
Core tap last commit: 6 hours ago
HOMEBREW_PREFIX: /usr/local
HOMEBREW_NO_ANALYTICS_THIS_RUN: 1
CPU: quad-core 64-bit broadwell
Homebrew Ruby: 2.3.3 => /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/bin/ruby
Clang: 9.1 build 902
Git: 2.15.2 => /Library/Developer/CommandLineTools/usr/bin/git
Curl: 7.54.0 => /usr/bin/curl
Java: 1.8.0_144, 1.8.0_111
macOS: 10.13.5-x86_64
CLT: 9.4.1.0.1.1528165917
Xcode: 9.4.1
XQuartz: N/A
OS information
MacOS High Sierra
version 10.13.5
I tried to chown my tmp file but I realize that the permission are fine.
drwxr-xr-x 11 _mysql _mysql 352 Jun 18 15:42 tmp
How do I correct this issue?

Related

libncurses.so.5 - cannot open shared library, Fedora

I am getting this error when I try to run a 64-bit program on a new 64-bit Fedora 28 installation.
I have tried to install the ncurses library these ways:
sudo yum install ncurses-libs
sudo dnf install ncurses-devel
yum provides libncurses.so.5
There is no file called libncurses.so.5 anywhere on the filesystem. There is a file in /usr/lib64 call libncurses.so.6 and I tried renaming this to 5 but then it says libtinfo.so.5 is missing.
I get this:
[username#localhost project]$ ./main ./demo.conf
./main: error while loading shared libraries: libncurses.so.5: cannot open shared object file: No such file or directory
These are my commands and their output:
[username#localhost ~]$ sudo yum install ncurses-devel
[sudo] password for username:
Fedora 28 - x86_64 371 kB/s | 60 MB 02:46
Last metadata expiration check: 0:01:24 ago on Sat 04 Aug 2018 09:34:19 PM PDT.
Dependencies resolved.
================================================================================
Package Arch Version Repository Size
================================================================================
Installing:
ncurses-devel x86_64 6.1-5.20180224.fc28 updates 527 k
Upgrading:
ncurses x86_64 6.1-5.20180224.fc28 updates 377 k
ncurses-base noarch 6.1-5.20180224.fc28 updates 80 k
ncurses-libs x86_64 6.1-5.20180224.fc28 updates 307 k
Installing dependencies:
ncurses-c++-libs x86_64 6.1-5.20180224.fc28 updates 54 k
Transaction Summary
================================================================================
Install 2 Packages
Upgrade 3 Packages
Total download size: 1.3 M
Is this ok [y/N]: y
Downloading Packages:
(1/5): ncurses-c++-libs-6.1-5.20180224.fc28.x86 51 kB/s | 54 kB 00:01
(2/5): ncurses-base-6.1-5.20180224.fc28.noarch. 65 kB/s | 80 kB 00:01
(3/5): ncurses-libs-6.1-5.20180224.fc28.x86_64. 127 kB/s | 307 kB 00:02
(4/5): ncurses-devel-6.1-5.20180224.fc28.x86_64 152 kB/s | 527 kB 00:03
(5/5): ncurses-6.1-5.20180224.fc28.x86_64.rpm 234 kB/s | 377 kB 00:01
--------------------------------------------------------------------------------
Total 296 kB/s | 1.3 MB 00:04
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Preparing : 1/1
Upgrading : ncurses-base-6.1-5.20180224.fc28.noarch 1/8
Upgrading : ncurses-libs-6.1-5.20180224.fc28.x86_64 2/8
Installing : ncurses-c++-libs-6.1-5.20180224.fc28.x86_64 3/8
Installing : ncurses-devel-6.1-5.20180224.fc28.x86_64 4/8
Upgrading : ncurses-6.1-5.20180224.fc28.x86_64 5/8
Cleanup : ncurses-6.1-4.20180224.fc28.x86_64 6/8
Cleanup : ncurses-libs-6.1-4.20180224.fc28.x86_64 7/8
Cleanup : ncurses-base-6.1-4.20180224.fc28.noarch 8/8
Running scriptlet: ncurses-base-6.1-4.20180224.fc28.noarch 8/8
Verifying : ncurses-devel-6.1-5.20180224.fc28.x86_64 1/8
Verifying : ncurses-c++-libs-6.1-5.20180224.fc28.x86_64 2/8
Verifying : ncurses-libs-6.1-5.20180224.fc28.x86_64 3/8
Verifying : ncurses-base-6.1-5.20180224.fc28.noarch 4/8
Verifying : ncurses-6.1-5.20180224.fc28.x86_64 5/8
Verifying : ncurses-6.1-4.20180224.fc28.x86_64 6/8
Verifying : ncurses-base-6.1-4.20180224.fc28.noarch 7/8
Verifying : ncurses-libs-6.1-4.20180224.fc28.x86_64 8/8
Installed:
ncurses-devel.x86_64 6.1-5.20180224.fc28
ncurses-c++-libs.x86_64 6.1-5.20180224.fc28
Upgraded:
ncurses.x86_64 6.1-5.20180224.fc28
ncurses-base.noarch 6.1-5.20180224.fc28
ncurses-libs.x86_64 6.1-5.20180224.fc28
Complete!
[username#localhost project]$ sudo yum install ncurses-libs
Last metadata expiration check: 0:05:45 ago on Sat 04 Aug 2018 09:34:19 PM PDT.
Package ncurses-libs-6.1-5.20180224.fc28.x86_64 is already installed, skipping.
Dependencies resolved.
Nothing to do.
Complete!
[username#localhost project]$ yum provides libncurses.so.5
Fedora 28 - x86_64 3.1 MB/s | 60 MB 00:19
Last metadata expiration check: 0:00:28 ago on Sat 04 Aug 2018 09:48:51 PM PDT.
ncurses-compat-libs-6.1-5.20180224.fc28.i686 : Ncurses compatibility libraries
Repo : updates
Matched from:
Provide : libncurses.so.5
ncurses-compat-libs-6.1-4.20180224.fc28.i686 : Ncurses compatibility libraries
Repo : fedora
Matched from:
Provide : libncurses.so.5
Try to install ncurses-compat-libs.
You would first use
dnf provides */libncurses.so.5
which can help you find a package that provides the file, and then install the respective package,
dnf install ncurses-compat-libs
in this case.
Just try to install the libncurses5 library:
apt install libncurses5
For more information, see this Reddit post.
I was able to solve this bug by installing that package.
For centos 8, encountered during couchbase install
dnf search libncurses
You will see list of packages with libcurses, you no need to download and install rpm package from official repo, just install from comand line only
sudo yum install ncurses-compat-libs

CentOS error while compiling Bind with DLZ "/usr/bin/ld: cannot find -lmysqlclient"

So I am trying to compile Bind with DLZ ( mysql ) support on CentOS 7
After doing
./configure --prefix=/usr --sysconfdir=/etc/bind --localstatedir=/var --mandir=/usr/share/man --infodir=/usr/share/info --enable-threads --enable-largefile --with-libtool --enable-shared --enable-static --with-openssl=/usr --with-gssapi=/usr --with-gnu-ld --with-dlz-postgres=no --with-dlz-mysql=yes --with-dlz-bdb=no --with-dlz-filesystem=yes --with-dlz-stub=yes --enable-ipv6
and
make
I get the error:
/opt/bind/bind-9.11.0-P3/lib/isc/.libs/libisc.so ../../lib/isc/.libs/libisc.so -lcrypto -L/usr/lib/mysql -lmysqlclient -lcrypt -lm -ldl -lz -lpthread
/usr/bin/ld: cannot find -lmysqlclient
collect2: error: ld returned 1 exit status
make[2]: *** [named] Error 1
make[2]: Leaving directory `/opt/bind/bind-9.11.0-P3/bin/named'
make[1]: *** [subdirs] Error 1
make[1]: Leaving directory `/opt/bind/bind-9.11.0-P3/bin'
make: *** [subdirs] Error 1
I have gotten it to work on one CentOS 7 box, however I installed all sorts of whacky stuff while trying to get it to work. I don't actually know why it compiles on that machine, and I would like to be able to replicate the process. So I created a fresh install of CentOS 7 and try and find out how to compile Bind with DLZ support. Bind 9.11.0-P3.
I have mariadb-libs installed and the /usr/lib64/mysql directory looks like this.
ll /usr/lib64/mysql/
total 16884
-rw-r--r--. 1 root root 2687 Nov 14 15:15 INFO_BIN
-rw-r--r--. 1 root root 170 Sep 12 2016 INFO_SRC
lrwxrwxrwx. 1 root root 17 Mar 29 16:40 libmysqlclient_r.so -> libmysqlclient.so
lrwxrwxrwx. 1 root root 20 Mar 29 16:40 libmysqlclient.so -> libmysqlclient.so.18
lrwxrwxrwx. 1 root root 24 Mar 29 16:40 libmysqlclient.so.18 -> libmysqlclient.so.18.0.0
-rwxr-xr-x. 1 root root 3135736 Nov 14 15:17 libmysqlclient.so.18.0.0
lrwxrwxrwx. 1 root root 15 Mar 29 16:40 libmysqld.so -> libmysqld.so.18
-rwxr-xr-x. 1 root root 14116296 Nov 14 15:17 libmysqld.so.18
-rwxr-xr-x. 1 root root 10474 Nov 14 15:14 mysqlbug
-rwxr-xr-x. 1 root root 6758 Nov 14 15:15 mysql_config
drwxr-xr-x. 2 root root 4096 Mar 29 16:40 plugin
The /usr/lib/mysql directory looks like this.
ll /usr/lib/mysql/
total 0
drwxr-xr-x. 2 root root 6 Mar 29 21:36 plugin
On the machine that Bind Compiles on the /usr/lib/mysql folder looks different, and when I do yum whatprovides on the other machine I get this result:
yum whatprovides /usr/lib/mysql/libmysqlclient.so.18.0.0
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: centos.mirror.ca.planethoster.net
* extras: centos.mirror.ca.planethoster.net
* updates: mirror.it.ubc.ca
* webtatic: us-east.repo.webtatic.com
1:mariadb-libs-5.5.52-1.el7.i686 : The shared libraries required for MariaDB/MySQL clients
Repo : base
Matched from:
Filename : /usr/lib/mysql/libmysqlclient.so.18.0.0
1:mariadb-libs-5.5.52-1.el7.x86_64 : The shared libraries required for MariaDB/MySQL clients
Repo : #base
Matched from:
Filename : /usr/lib/mysql/libmysqlclient.so.18.0.0
On the fresh install I have installed these mariadb packages.
yum list mariadb*
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
* base: mirror.its.sfu.ca
* extras: centos.bhs.mirrors.ovh.net
* updates: mirror.its.sfu.ca
Installed Packages
mariadb.x86_64 1:5.5.52-1.el7 #base
mariadb-bench.x86_64 1:5.5.52-1.el7 #base
mariadb-devel.x86_64 1:5.5.52-1.el7 #base
mariadb-embedded.x86_64 1:5.5.52-1.el7 #base
mariadb-embedded-devel.x86_64 1:5.5.52-1.el7 #base
mariadb-libs.x86_64 1:5.5.52-1.el7 #base
mariadb-server.x86_64 1:5.5.52-1.el7 #base
mariadb-test.x86_64 1:5.5.52-1.el7 #base
Available Packages
Please help me figure out how to install Bind with DLZ support on CentOS 7!
Add 'LDFLAGS="-I/usr/include/mysql -L/usr/lib64/mysql"'
on to the ./configure command
like so
./configure --prefix=/usr --sysconfdir=/etc/bind --localstatedir=/var --mandir=/usr/share/man --infodir=/usr/share/info --enable-threads --enable-largefile --with-libtool --enable-shared --enable-static --with-openssl=/usr --with-gssapi=/usr --with-gnu-ld --with-dlz-postgres=no --with-dlz-mysql=yes --with-dlz-bdb=no --with-dlz-filesystem=yes --with-dlz-stub=yes --enable-ipv6 LDFLAGS="-I/usr/include/mysql -L/usr/lib64/mysql"

MAC OS X: Installed MySQL, Cannot locate MySQLCOM/ directory under /Library/StartupItems/ directory

I'm working on Mac OS X Yosemite (version: 10.10.5) and I want to use MySQL as database for my web app.
I downloaded MySQL -- "mysql-5.7.10-osx10.9-x86_64.dmg", and successfully installed it.
I'm following the steps given in:
http://geeksww.com/tutorials/database_management_systems/mysql/installation/how_to_download_and_install_mysql_on_mac_os_x.php
Where I'm at this step --
**"Install and setup auto start package for MySQL on OS X":**
you should now be able to start MySQL running the following command in OS X Terminal window
$ sudo /Library/StartupItems/MySQLCOM/MySQLCOM start
However I'm unable to locate MySQLCOM directory under /Library/StartupItems/ directory
[Terminal]:$ pwd
/Library/StartupItems
[Terminal]:$ ls -l
total 0
drwxr-xr-x 5 root wheel 170 Dec 7 22:55 HWNetMgr
drwxr-xr-x 6 root wheel 204 Dec 7 22:55 HWPortDetect
drwxr-xr-x 10 root wheel 340 Dec 7 22:55 StartOuc
drwxr-xr-x 3 root wheel 102 Sep 30 14:12 cma

New SQL Install already has me locked out for root

I am going a bit bonkers over this but this is what is happening.
I am installing mysql and mysql server but running the mysql_secure_installation and it already has me locked out of root.
Here's the full deal of what I went through. I have no idea what the password default may be but everyone keeps saying try "root" or just pressing enter (no password at all). How on earth am I locked out from the get go?
[root#Gretchen ~]# dnf install mysql mysql-server
Last metadata expiration check performed 1:52:35 ago on Tue Jan 5 10:07:03 2016.
Dependencies resolved.
=============================================================================================================================================================================================================================================
Package Arch Version Repository Size
=============================================================================================================================================================================================================================================
Installing:
mecab x86_64 0.996-1.fc23.3 fedora 393 k
mecab-ipadic x86_64 2.7.0.20070801-11.fc23.1 fedora 11 M
mysql-community-client x86_64 5.7.10-1.fc23 mysql57-community 25 M
mysql-community-common x86_64 5.7.10-1.fc23 mysql57-community 274 k
mysql-community-libs x86_64 5.7.10-1.fc23 mysql57-community 2.2 M
mysql-community-server x86_64 5.7.10-1.fc23 mysql57-community 105 M
Transaction Summary
=============================================================================================================================================================================================================================================
Install 6 Packages
Total download size: 143 M
Installed size: 670 M
Is this ok [y/N]: y
Downloading Packages:
(1/6): mysql-community-common-5.7.10-1.fc23.x86_64.rpm 629 kB/s | 274 kB 00:00
(2/6): mysql-community-libs-5.7.10-1.fc23.x86_64.rpm 609 kB/s | 2.2 MB 00:03
(3/6): mecab-0.996-1.fc23.3.x86_64.rpm 588 kB/s | 393 kB 00:00
(4/6): mecab-ipadic-2.7.0.20070801-11.fc23.1.x86_64.rpm 662 kB/s | 11 MB 00:16
(5/6): mysql-community-client-5.7.10-1.fc23.x86_64.rpm 1.0 MB/s | 25 MB 00:23
(6/6): mysql-community-server-5.7.10-1.fc23.x86_64.rpm 1.9 MB/s | 105 MB 00:55
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total 2.5 MB/s | 143 MB 00:56
Running transaction check
Transaction check succeeded.
Running transaction test
Transaction test succeeded.
Running transaction
Installing : mecab-0.996-1.fc23.3.x86_64 1/6
Installing : mysql-community-common-5.7.10-1.fc23.x86_64 2/6
Installing : mysql-community-libs-5.7.10-1.fc23.x86_64 3/6
Installing : mysql-community-client-5.7.10-1.fc23.x86_64 4/6
Installing : mecab-ipadic-2.7.0.20070801-11.fc23.1.x86_64 5/6
Installing : mysql-community-server-5.7.10-1.fc23.x86_64 6/6
Verifying : mysql-community-client-5.7.10-1.fc23.x86_64 1/6
Verifying : mysql-community-libs-5.7.10-1.fc23.x86_64 2/6
Verifying : mysql-community-common-5.7.10-1.fc23.x86_64 3/6
Verifying : mysql-community-server-5.7.10-1.fc23.x86_64 4/6
Verifying : mecab-0.996-1.fc23.3.x86_64 5/6
Verifying : mecab-ipadic-2.7.0.20070801-11.fc23.1.x86_64 6/6
Installed:
mecab.x86_64 0.996-1.fc23.3 mecab-ipadic.x86_64 2.7.0.20070801-11.fc23.1 mysql-community-client.x86_64 5.7.10-1.fc23 mysql-community-common.x86_64 5.7.10-1.fc23 mysql-community-libs.x86_64 5.7.10-1.fc23
mysql-community-server.x86_64 5.7.10-1.fc23
Complete!
[root#Gretchen ~]#
[root#Gretchen ~]# service mysqld start
Redirecting to /bin/systemctl start mysqld.service
[root#Gretchen ~]#
[root#Gretchen ~]#
[root#Gretchen ~]# cd /usr/bin
[root#Gretchen bin]# mysql_secure_installation
Securing the MySQL server deployment.
Enter password for user root:
Error: Access denied for user 'root'#'localhost' (using password: NO)
[root#Gretchen bin]# mysql_secure_installation
Securing the MySQL server deployment.
Enter password for user root:
Error: Access denied for user 'root'#'localhost' (using password: YES)
[root#Gretchen bin]#
of course if I uninstall and re-install this continues to happen. I'm afraid I may have installed something else that I should be uninstalling also but I'm unsure.
I have no interest in keeping any databases or users or anything. I just want to have SQL starting from scratch without having to redo my entire server.
Typically mysql stores your initial root password would be stored in /root/.mysql_secret. Check it out.
You may have to start the service with:
service mysql start
Then try mysql_secure_installation again.

Can't install MySQL 5.6 by RPM

I'm trying to install MySQL 5.6 community edition from the RPM package I downloaded. I'm running on cloudera's CDH 4.5 virtual machine, which is CentOS 6.4. The VM came with MySQL 5.1.73 installed, the old versions of files seem to be blocking me from updating.
I already did this:
sudo yum remove mysql
and that worked just fine, without a problem. Then I deleted everything in /usr/lib/mysql, aka the data directory. So then I tried installing the new version:
[cloudera#localhost mysql]$ pwd
/home/cloudera/mysql
[cloudera#localhost mysql]$ ll
total 302660
-rw-r--r-- 1 cloudera cloudera 23080383 Mar 17 02:39 MySQL-client-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 4573735 Mar 17 02:40 MySQL-devel-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 114192347 Mar 17 02:40 MySQL-embedded-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 86961692 Mar 17 02:41 MySQL-server-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 2398671 Mar 17 02:41 MySQL-shared-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 5180653 Mar 17 02:41 MySQL-shared-compat-5.6.17-1.linux_glibc2.5.x86_64.rpm
-rw-r--r-- 1 cloudera cloudera 73530987 Mar 17 02:42 MySQL-test-5.6.17-1.linux_glibc2.5.x86_64.rpm
[cloudera#localhost mysql]$ sudo yum install MySQL-server-5.6.17-1.linux_glibc2.5.x86_64.rpm
.....
Downloading Packages:
Running rpm_check_debug
Running Transaction Test
Transaction Check Error:
file /usr/share/mysql/charsets/README from install of MySQL-server-5.6.17-1.linux_glibc2.5.x86_64 conflicts with file from package mysql-libs-5.1.73-3.el6_5.x86_64
file /usr/share/mysql/czech/errmsg.sys from install of MySQL-server-5.6.17-1.linux_glibc2.5.x86_64 conflicts with file from package mysql-libs-5.1.73-3.el6_5.x86_64
......
So it looks like the old installation is blocking me, I tried to delete mysql-libs but...
[cloudera#localhost mysql]$ sudo yum remove mysql-libs
.....
pig noarch 0.11.0+33-1.cdh4.4.0.p0.14.el6 #cloudera-cdh4 120 M
postfix x86_64 2:2.6.6-2.2.el6_1 #anaconda-CentOS-201112091719.x86_64/6.2 9.7 M
redhat-lsb x86_64 4.0-7.el6.centos #base 0.0
redhat-lsb-compat x86_64 4.0-7.el6.centos #base 0.0
redhat-lsb-core x86_64 4.0-7.el6.centos #base 22 k
redhat-lsb-graphics x86_64 4.0-7.el6.centos #base 0.0
redhat-lsb-printing x86_64 4.0-7.el6.centos #base 0.0
solr noarch 4.4.0+69-1.cdh4.3.0.p0.4.el6 #cloudera-search 66 M
solr-mapreduce noarch 1.0.0-1.cdh4.3.0.p0.5.el6 #cloudera-search 55 M
sqoop noarch 1.4.3+62-1.cdh4.4.0.p0.15.el6 #cloudera-cdh4 7.7 M
sqoop2 noarch 1.99.2+85-1.cdh4.4.0.p0.62.el6 #cloudera-cdh4 7.8 M
sysstat x86_64 9.0.4-20.el6 #base 807 k
tomcat noarch 7.0.33-3.el6 #epel 303 k
Transaction Summary
=============================================================================================================================================================================================
Remove 67 Package(s)
It went and listed a lot of major software that depends on mysql-libs. I don't want to reinstall tomcat, pig, hive, mahout, hue, oozie, flume, and cloudera manager. I have worked with those before, I know that they are a NIGHTMARE to get installed and configured correctly, so I really don't want to uninstall those.
So I thought maybe I should try an update instead,
[cloudera#localhost mysql]$ sudo yum update MySQL-server-5.6.17-1.linux_glibc2.5.x86_64.rpm
....
Examining MySQL-server-5.6.17-1.linux_glibc2.5.x86_64.rpm: MySQL-server-5.6.17-1.linux_glibc2.5.x86_64
Package MySQL-server not installed, cannot update it. Run yum install to install it instead.
No Packages marked for Update
It will not let me update it because I already removed it.
Would somebody please tell me how to install MySQL from these RPMs without uninstalling everything else?
Try to install shared-compat packages as you can see here.
I'm just going to re-write the answer for anybody else who comes across this.
Download the mysql yum repo if you don't already have it: http://dev.mysql.com/downloads/file.php?id=450542
If you have an old version of mysql installed, just do a yum update mysql. You may also need to do yum update mysql-server.
If you uninstalled it, try to reinstall now that you have the new yum repo. If it still fails due to a Transaction check error, try deleting any files that it lists in conflict. Be careful not to delete any files you want to keep.
you may also need to do 'sudo yum update mysql-server' or 'sudo yum install mysql-server'. I did.
I will mark acfrai's answer correct to give him credit, he helped lead me to this information.