HBase does not run after ./start-hbase.sh - Permission Denied?
you say the output of ls -l start-hbase.sh is :
-rwxr-xr-x 1 root root 1872 huhti 4 2013 start-hbase.sh
if you want to know what user and group you are logging with , there us simple way:
touch test
ls -l test
and check user:group ...
the problem is user owner and group owner of script.. you have two solutions:
1) sudo chown hduser:hduser start-hbase.sh #here hduser is example...you should know what user and group you have,,,
inorder to make it your slave...with executable state(sudo chmod +x start-hbase.sh
)
2) you can be root by: "su root" or "sudo su" or "sudo bash"
and then execute the script...
Nazanin
Updated on August 22, 2022Comments
-
Nazanin over 1 year
I want to run HBase. I have installed hadoop completely and when I run
start-all.sh
, it works fine and gives me this output:hduser@CSLAP106:/usr/local/hadoop/bin$ jps 11956 SecondaryNameNode 12046 JobTracker 12193 TaskTracker 11800 DataNode 11656 NameNode 12254 Jps
But when I want to run
start-hbase.sh
, it gives me some errors of permission denied which I do not understand why:hduser@CSLAP106:/usr/local/hbase/hbase-0.94.6.1/bin$ ./start-hbase.sh localhost: starting zookeeper, logging to /usr/local/hbase/hbase-0.94.6.1/bin/../logs/hbase-hduser-zookeeper-CSLAP106.out localhost: /usr/local/hbase/hbase-0.94.6.1/bin/hbase-daemon.sh: line 150: /usr/local/hbase/hbase-0.94.6.1/bin/../logs/hbase-hduser-zookeeper-CSLAP106.log: Permission denied localhost: head: cannot open ‘/usr/local/hbase/hbase-0.94.6.1/bin/../logs/hbase-hduser-zookeeper-CSLAP106.out’ for reading: No such file or directory /usr/local/hbase/hbase-0.94.6.1/bin/hbase-daemon.sh: line 150: /usr/local/hbase/hbase-0.94.6.1/bin/../logs/hbase-hduser-master-CSLAP106.log: Permission denied head: cannot open ‘/usr/local/hbase/hbase-0.94.6.1/bin/../logs/hbase-hduser-master-CSLAP106.out’ for reading: No such file or directory localhost: starting regionserver, logging to /usr/local/hbase/hbase-0.94.6.1/bin/../logs/hbase-hduser-regionserver-CSLAP106.out localhost: /usr/local/hbase/hbase-0.94.6.1/bin/hbase-daemon.sh: line 150: /usr/local/hbase/hbase-0.94.6.1/bin/../logs/hbase-hduser-regionserver-CSLAP106.log: Permission denied localhost: head: cannot open ‘/usr/local/hbase/hbase-0.94.6.1/bin/../logs/hbase-hduser-regionserver-CSLAP106.out’ for reading: No such file or directory
after that, I tried to run
sudo ./start-hbase.sh
, and I got something more weird!root@localhost's password:
I do not know what I am supposed to type here. anyway I just clicked Enter and it switched back to
hduser
again:root@localhost's password: root@localhost's password: localhost: Permission denied, please try again. root@localhost's password: localhost: Permission denied, please try again. localhost: Permission denied (publickey,password). starting master, logging to /usr/local/hbase/hbase-0.94.6.1/bin/../logs/hbase-root- master-CSLAP106.out root@localhost's password: root@localhost's password: localhost: Permission denied, please try again. root@localhost's password: localhost: Permission denied, please try again. localhost: Permission denied (publickey,password). hduser@CSLAP106:/usr/local/hbase/hbase-0.94.6.1/bin$
I put some lines from my
hbase-env.sh
andhbase-site.xml
files in case they are needed:hbase-env.sh
# File naming hosts on which HRegionServers will run. $HBASE_HOME/conf/regionservers by default. export HBASE_REGIONSERVERS=/usr/local/hbase/hbase-0.94.6.1/conf/regionservers # File naming hosts on which backup HMaster will run. $HBASE_HOME/conf/backup-masters by default. export HBASE_BACKUP_MASTERS=/usr/local/hbase/hbase-0.94.6.1/conf/backup-masters # Tell HBase whether it should manage it's own instance of Zookeeper or not. export HBASE_MANAGES_ZK=true
hbase-site.xml
<configuration> <property> <name>hbase.rootdir</name> <value>hdfs://localhost:54310/hbase</value> </property> <property> <name>hbase.cluster.distributed</name> <value>true</value> </property>
So, what do you think is wrong with HBase that it does not run! I am really getting exhausted with this. It has been weeks I am working on it and every time it comes up with a new error. I would really appreciate your time and effort to help me :)
-
MLSC over 10 yearsthe first solution works as well...you need to know what your user ang group is...a solution is by touching file and see the result of ls -l...your welcome
-
MLSC over 10 yearsno,,,linux is so sweet...pay attention that first solution was possible as well..just need to know what user ang group your are at...
-
Nazanin over 10 yearsYeah,I'm really starting to like working with it. I have encountered a problem again! When I run
start-hbase.sh
it shows that it is logging to themaster
,zookeeper
andregionserver
, and without any errors, it logs in. But when I typejps
, I seeHregionserver
but notHMaster
. And when I runlocalhost: 60010
in my browser, it does not show anything :( -
MLSC over 10 yearswhich distro are you using? centos? ubuntu?
-
Nazanin over 10 yearsUbuntu 13.10 The funny thing is that, after I have started hbase, now I want to stop it, but it does not stop, nor does it show the output I want! Do I need to do another installation and start everything from the scratch? The problem is that there is no one who has worked with hadoop and hbase before around me, and I have to do this project!
-
Nazanin over 10 yearsIsn't this weird?: stopping hbase root@CSLAP106:~# jps 17155 HMaster 17248 Jps 6806 HRegionServer ... It says it is stopping, but still shows HMaster and HRegionServer!
-
Nazanin over 10 yearsI think I have to start everything from the beginning! It is not working maybe because I have done some changes to some parts and I am not aware of them! You know, it's been 2 months I am working on this, and I could not even get the single node cluster to work properly!
-
MLSC over 10 yearsI haven't worked with hbase.but generally if you want to stop a script you should kill the process(ps aux | grep script.sh)--then see the process id.after that:(kill -9 <pid>)===if 60010 doesn't work you should work with firewall and allow this port.now for pass this problem do(sudo ufw disable)
-
MLSC over 10 yearsask your new problem in this site someone would help you
-
Nazanin over 10 yearsYes,sure. Thank you for your help all through the way :)