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

IOError: [Errno 2] No such file or directory: '/home/ec2-user/pacbot/dist/jobs/rule-engine.jar' #57

Closed
marcschroeter opened this issue Nov 16, 2018 · 24 comments
Assignees
Labels
help wanted Extra attention is needed

Comments

@marcschroeter
Copy link

Started building the jar...............

Traceback (most recent call last):
File "setup_pacman.py", line 213, in
_access_validation(assignedpolicieslist, user_name, user_arn)
File "setup_pacman.py", line 190, in _access_validation
awsterraformbuild._create_aws_resources(accessKey, secretKey, region)
File "/home/ec2-user/pacbot/installer/awsterraformbuild.py", line 28, in _create_aws_resources
jsonRead._build_ui_apps(aws_access_key, aws_secret_key, region)
File "/home/ec2-user/pacbot/installer/jsonRead.py", line 760, in _build_ui_apps
bucket=_get_s3_bucket_name() + '-' + _get_base_accountid()
File "/home/ec2-user/pacbot/installer/ui/build_apps.py", line 37, in build_api_and_ui_apps
self.build_jar_and_ui_from_code()
File "/home/ec2-user/pacbot/installer/ui/build_apps.py", line 84, in build_jar_and_ui_from_code
self.copy_jars_to_upload_dir(self.codebase_root_dir)
File "/home/ec2-user/pacbot/installer/ui/build_apps.py", line 113, in copy_jars_to_upload_dir
shutil.copy2(copy_file_from, self.upload_dir)
File "/usr/lib64/python2.7/shutil.py", line 144, in copy2
copyfile(src, dst)
File "/usr/lib64/python2.7/shutil.py", line 96, in copyfile
with open(src, 'rb') as fsrc:
IOError: [Errno 2] No such file or directory: '/home/ec2-user/pacbot/dist/jobs/rule-engine.jar'

@marcschroeter
Copy link
Author

Is there a chance someone can help us what we need to change to solve that problem? We are just using a clean AWS Linux 2 AMI and installing the components as in your description

@Leectan
Copy link

Leectan commented Nov 20, 2018

@marcschroeter I have similar issue, I believe this issue has to do with Java9, I'm testing out with Java8 to see if it is working...

@marcschroeter
Copy link
Author

@Leectan but it looks like i have Java 8 installed

java -version
openjdk version "1.8.0_191"
OpenJDK Runtime Environment (build 1.8.0_191-b12)
OpenJDK 64-Bit Server VM (build 25.191-b12, mixed mode)

@johnakash
Copy link
Collaborator

Hey @marcschroeter , Could you please let us know the machine configuration from which you are trying to install pacbot? The machine need to have at-least 8GB of memory to complete successful build.

@marcschroeter
Copy link
Author

Thank you so much! I could it install now @johnakash

But i am not able to login with default credentials
Admin User : admin@pacbot.org / pacman
Readonly User : user@pacbot.org / user

Authentication Failed. Please check your credentials.

@Leectan
Copy link

Leectan commented Nov 21, 2018

@marcschroeter if you could enumerate how you install the pip dependencies and java and maven, and OS you are running on would be great. I'm sure it would be a great help.

@Leectan
Copy link

Leectan commented Nov 21, 2018

@marcschroeter I get these errors along the way when I tried to install it. Wondering if you experienced the same..

screen shot 2018-11-21 at 11 18 29 am

screen shot 2018-11-21 at 11 19 24 am

@Leectan
Copy link

Leectan commented Nov 21, 2018

@marcschroeter looks like I have the same issue as you had before... wondering what you did differently here.

screen shot 2018-11-21 at 11 38 33 am

@johnakash
Copy link
Collaborator

@Leectan since installer building UI and API jars together on the fly we need to make use an instance with minimum 8GB memory. Please upgrade the machine configuration and give a try.

Before running the installer again, please make sure you have executed destroy command and cleaned all resources created as part of PacBot

  • IAM role and policy
  • S3 bucket
  • RDS
  • Redshift
  • ElasticSearch
  • SecurityGroup
  • ECS
  • Batch

@Leectan
Copy link

Leectan commented Nov 21, 2018

@johnakash I'm running on Ubuntu 4GB CPU and 16GB memory....

@Leectan
Copy link

Leectan commented Nov 21, 2018

@johnakash it looks alot like software dependencies are broken to me... especially Java and Maven....

@johnakash
Copy link
Collaborator

@marcschroeter Could you please check if you can see tables of oauth_user table in RDS?

@johnakash
Copy link
Collaborator

@Leectan Please join on gitter, we can have a quick chat and close it out.

@Leectan
Copy link

Leectan commented Nov 21, 2018

@johnakash gitter link please

@Leectan
Copy link

Leectan commented Nov 21, 2018

@johnakash nvm, saw.

@marcschroeter
Copy link
Author

@Leectan this is what i am doing on a Amzaon Linux 2 AMI:

sudo yum install git -y
sudo yum install -y epel-release python-pip
wget https://raw.githubusercontent.com/tmobile/pacbot/master/installer/requirements.txt
sudo pip install -r requirements.txt
sudo yum -y install java-1.8.0-openjdk npm docker maven wget unzip mysql
sudo amazon-linux-extras install docker
sudo systemctl start docker #amazonlinux2
sudo service docker start #amazonlinux
wget https://releases.hashicorp.com/terraform/0.11.8/terraform_0.11.8_linux_amd64.zip
unzip terraform_0.11.8_linux_amd64.zip
sudo mv terraform /bin/
git clone git@github.com:tmobile/pacbot.git

@marcschroeter
Copy link
Author

@johnakash how can i connect to the RDS DB? How can i find the credentials?

@johnakash
Copy link
Collaborator

@Leectan this is what i am doing on a Amzaon Linux 2 AMI:

sudo yum install git -y
sudo yum install -y epel-release python-pip
wget https://raw.githubusercontent.com/tmobile/pacbot/master/installer/requirements.txt
sudo pip install -r requirements.txt
sudo yum -y install java-1.8.0-openjdk npm docker maven wget unzip mysql
sudo amazon-linux-extras install docker
sudo systemctl start docker #amazonlinux2
sudo service docker start #amazonlinux
wget https://releases.hashicorp.com/terraform/0.11.8/terraform_0.11.8_linux_amd64.zip
unzip terraform_0.11.8_linux_amd64.zip
sudo mv terraform /bin/
git clone git@github.com:tmobile/pacbot.git

Could you please check if maven installed in the machine?

@marcschroeter
Copy link
Author

@johnakash when i excecute "mvn versions:display-dependency-updates" i get this. Is this what you need to know?

[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building PacMan 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- versions-maven-plugin:2.7:display-dependency-updates (default-cli) @ pacbot ---
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] api-commons ....................................... SUCCESS [6.859s]
[INFO] commons ........................................... SUCCESS [2.874s]
[INFO] PacMan Commons Projects ........................... SUCCESS [0.005s]
[INFO] admin-service ..................................... SUCCESS [3.177s]
[INFO] asset-service ..................................... SUCCESS [36.497s]
[INFO] config ............................................ SUCCESS [2.609s]
[INFO] compliance-service ................................ SUCCESS [0.444s]
[INFO] notification-service .............................. SUCCESS [0.475s]
[INFO] statistics-service ................................ SUCCESS [0.394s]
[INFO] auth-service ...................................... SUCCESS [0.496s]
[INFO] PacMan Api Projects ............................... SUCCESS [0.003s]
[INFO] inventoryFetch .................................... SUCCESS [0.227s]
[INFO] data-shipper ...................................... SUCCESS [0.008s]
[INFO] awsrules .......................................... SUCCESS [0.112s]
[INFO] pacman-rule-engine ................................ SUCCESS [0.347s]
[INFO] PacMan Jobs Projects .............................. SUCCESS [0.003s]
[INFO] PacBot UI ......................................... SUCCESS [0.562s]
[INFO] PacMan ............................................ SUCCESS [0.002s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1:00.021s
[INFO] Finished at: Wed Nov 21 20:58:35 UTC 2018
[INFO] Final Memory: 42M/791M
[INFO] ------------------------------------------------------------------------
[ec2-user@ip-10-0-0-95 pacbot]$ mvn versions:display-dependency-updates

@johnakash
Copy link
Collaborator

This looks good and the PacBot is seems to be installed in your account. At the end of installation the Portal URL (to login) and default login details will be printed. Please try to login with those credentials.

@marcschroeter
Copy link
Author

marcschroeter commented Nov 21, 2018

i am not able to login with default credentials
Admin User : admin@pacbot.org / pacman
Readonly User : user@pacbot.org / user

Authentication Failed. Please check your credentials.

@marcschroeter
Copy link
Author

this was the output - but i cannot login with that - i can see the website but then get Authentication Failed. Please check your credentials.


********** Login Domain: internal-pacbot-xxxxxxx.eu-central-1.elb.amazonaws.com
***************** Admin: admin@pacbot.org / pacman
****************** User: user@pacbot.org / user


@johnakash
Copy link
Collaborator

@marcschroeter , Please let us know when you can be available to troubleshoot the issue in Gitter.

@santhoshigorle santhoshigorle added the help wanted Extra attention is needed label Dec 4, 2018
@johnakash
Copy link
Collaborator

We are closing this issue since there is no response for the last 7 days.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

4 participants