Open Source RDBMS - Seamless, Scalable, Stable and Free

한국어 | Login |Register

Permission Denied Error


In the following tutorial, we will present how to handle permission denied error on Linux systems. CUBRID can be installed using various approaches according to the operating system. We will assume you have followed one of the methods listed here: http://www.cubrid.org/wiki_tutorials/entry/cubrid-installation-instructions

Troubleshooting Permission Denied Error on Ubuntu

This section of the tutorial assumes that you have installed CUBRID using the apt-get repositories as stated in the Installing CUBRID on Ubuntu tutorial.

Before we get started, you should make sure you have read the Installation Notes for installing CUBRID on Ubuntu. If you encounter any error or failure running a service command such as "service cubrid start", then you should check the output of /var/opt/cubrid/tmp/service.cubrid and see the reason of the error.

One common cause of [FAIL] message during a service command is the permission denied error. If you get this error, you have to check that there are not files within /opt/cubrid that are not owned by cubrid user and group and that the cubrid user has read access on the files in /etc/opt/cubrid and read+write access on the files in /var/opt/cubrid (where it creates the logs and database files).

Important! Other errors, such as being unable to get shared memory are due to the fact that the user that runs the cubrid service (in this case the cubrid user) does not have rights inside the folder where CUBRID is installed (/opt/cubrid in this situation).

Note: To change the rights, you can run chmod cubrid:cubrid on any file or folder (cubrid is the user and group in this case). Use -R to recursively apply to rule to all subfolders.

Troubleshooting Permission Denied Error on Fedora/Centos

This section of the tutorial assumes that you have installed CUBRID using the yum repositories as stated in the Installing CUBRID on Fedora or Centos tutorial.

Before we get started, you should make sure you have read the Installation Notes for installing CUBRID on Fedora or Centos. If you encounter any error or failure running a service command such as "service cubrid start", then you should check the output of /var/cubrid/tmp/service.cubrid and see the reason of the error.

One common cause of [FAIL] message during a service command is the permission denied error. If you get this error, you have to check that there are not files within /usr/share/cubrid that are not owned by cubrid user and group and that the cubrid user has read access on the files in /etc/cubrid and read+write access on the files in /var/cubrid (where it creates the logs and database files).

Important! Other errors, such as being unable to get shared memory are due to the fact that the user that runs the cubrid service (in this case the cubrid user) does not have rights inside the folder where CUBRID is installed (/usr/share/cubrid in this situation).

Troubleshooting Permission Denied Error on Linux

If neither of the two sections above apply to you, then that means you have either installed Ubuntu using the RPM, SH installer or you have simply extracted the zip archive.

The RPM Installer

The RPM installer copies all files in /opt/cubrid. Therefore you should check this folder for the user that owns the files and run the cubrid commands only using this user. Any other user (except of course the root user) will most likely receive permission denied errors.

The SH Installer

If this is the approach you used to install CUBRID, then it is entirely installed in the directory you specified, apart from the /home/$USER/.cubrid.sh file (where $USER is the username that installed cubrid). You must check that all files in the $CUBRID folder and subfolders are owned by the exact user that runs the cubrid commands.

The ZIP or TAR Archive

The same rule as with the SH Installer applies with the only difference that the .cubrid.sh file was not created.

comments powered by Disqus
Page info
viewed 3180 times
translations en
Author
posted 2 years ago by
CUBRID
Contributors
updated 2 years ago by
View revisions
Share this article