Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iptables: No chain/target/match by that name. #26

Open
ni3gavhane opened this issue Oct 17, 2019 · 13 comments
Open

iptables: No chain/target/match by that name. #26

ni3gavhane opened this issue Oct 17, 2019 · 13 comments

Comments

@ni3gavhane
Copy link

ni3gavhane commented Oct 17, 2019

Issue:
Some validator organization are commenting following lines in the installation scripts which results into unexpected end of the installation script.
line 65 to 68

echo "Securing SSH..."
writeSShConfig
semanage port -a -t ssh_port_t -p tcp 2222
service sshd restart

Result:
parity-keygen
parity-keygen
Creating docker-stack_parity-telemetry_1 ... done
Creating docker-stack_nodecontrol_1 ... done
Creating docker-stack_parity_1 ... done
Waiting 30 sec for parity to come up and generate the enode...
Redirecting to /bin/systemctl restart telegraf.service
Setting up firewall
iptables: No chain/target/match by that name.
iptables: Directory not empty.
iptables: Chain already exists.
iptables: No chain/target/match by that name.

Expected Outcome:
Script should end with a proper installation summary.

Details:
Installation Script:
CentOS: https://github.com/energywebfoundation/ewc-validator-node-install-scripts/blob/master/volta-affiliate/install-validator-centos-7-volta.sh
Ubuntu: https://github.com/energywebfoundation/ewc-validator-node-install-scripts/blob/master/volta-affiliate/install-validator-ubuntu-server-18.04-volta.sh

@kazmen1983
Copy link

which distribution you are using? Is this CentOS ?

@ni3gavhane
Copy link
Author

One of the member has this problem on CentOS.

@kazmen1983
Copy link

it looks like iptables problem. Can they start script with the bash -x ./install-validator-centos-7-volta.sh and copy output?

@Juanyyo82
Copy link

Hi,
Is a virtual server in a local ESX server, with ubuntu 18.04.2 (install-validator-ubuntu-server-18.04-volta.sh). I did the instalation installation from scratch, fresh ubuntu server and full update OS.
I have tu put in line 178 "--no-check-certificate", Because we have a proxy server and the installation display this error: "ERROR: cannot verify raw.githubusercontent.com's certificate, issued by ‘CN=Myproxy’:"
Is there any problem to install the centos script in a rhel 7 OS?
Regards

@bartcoelus
Copy link

Hi. It was me facing this issues. First of all important: we configured our SSH on port 2222. The script reconfigures SSH - but can't handle if the config is already set to 2222.
Next to that we had a hard time with IPtables

iptables: No chain/target/match by that name.
iptables: Directory not empty.
iptables: Chain already exists.
iptables: No chain/target/match by that name.

@bartcoelus
Copy link

still unsolved... waiting for further instructions - Rodger

@kazmen1983
Copy link

I was asking for the running script with bash -x so I can look which Iptables rules are failing.

@bartcoelus
Copy link

docker: Error response from daemon: driver failed programming external connectivity on endpoint parity-keygen (59f......): Bind for 127.0.0.1:8545 failed: port is already allocated.

@bartcoelus
Copy link

not sure if this is due a previous version/deamon running... also I removed the key-info from this post (59f....) since I don't want to reveal anything harmfull in public

@ni3gavhane
Copy link
Author

ni3gavhane commented Oct 21, 2019

@bartcoelus can you please post the complete log. you can do something like following:
./installation_script.sh 2>&1 | tee debug.log

and share the debug.log

Also, it seems the parity instance is already running that is why you get the last error.
check that with the following command:

ps aux | grep parity

if you see processes running, kill them with kill -9 <PID>

then remove the docker-stack folder rm -rf docker-stack and re-run the script.

@bartcoelus
Copy link

done that - can I send you the debug.log somewhere outside github. I don't think we want all this stuff on this public page

@kazmen1983
Copy link

Client sended e-mail that now validator install works.

@bartcoelus
Copy link

bartcoelus commented Oct 24, 2019

Let's share important learnings from our case:

  1. The script defines port 2222 - since our firewall and SSH was already configured to use that port we needed to comment these lines. Maybe a good idea to throw-catch the event if the connection is already on that port.
  2. Needed to kill the docker containers in memory in order to clean up a failed install
  3. Important is to make sure the user operates from a root directory and not to install as default root
  4. We'd not recommend to name the node with IP-adress as default suggested in the script. When the IP adress ever changes it can cause confusion.
  5. Removal of docker-directories and spool files is needed in the case you need to redo the install. I refer to the wiki - it contains the directories and files that need to be removed at a failed attempt.
    https://energyweb.atlassian.net/wiki/spaces/EWF/pages/702513299/Volta+Setting+Up+a+New+Validator+Node

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants