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

awsr never gets past "Forking new awsr background process" #21

Closed
captainfalcon23 opened this issue Mar 15, 2022 · 7 comments
Closed

awsr never gets past "Forking new awsr background process" #21

captainfalcon23 opened this issue Mar 15, 2022 · 7 comments

Comments

@captainfalcon23
Copy link

Ï am trying to run awsr using python 3 in WSL.

Added to path.

Try to execute:

[root@blah ~]# awsr
Forking new awsr background process

In another WSL window, if i run a command like:

awsr ec2 describe-instances

It just tries again to fork a new background process. Even if I try to fork the command in the background it doesn't work.

Not sure if it's something to do with WSL?

@gaul
Copy link
Collaborator

gaul commented Mar 15, 2022

Could you try setting the environment variable AWSR_DAEMON=True for the server and AWSR_CLIENT=True for the clients? I also could not get the auto-detection working and the explicit flags make more sense to me.

@captainfalcon23
Copy link
Author

Still doesn't work...

$ AWSR_DAEMON=True
$ echo $AWSR_DAEMON
True
$ awsr
Forking new awsr background process

@captainfalcon23
Copy link
Author

Any thoughts ... ?

@matt-horwood-mayden
Copy link

matt-horwood-mayden commented Jun 6, 2022

have had the same issue, try this
export AWSR_DAEMON=True;./awsr

then run this
export AWSR_CLIENT=True; ../aws-cli-repl/awsr ec2 describe-instances

@captainfalcon23
Copy link
Author

have had the same issue, try this export AWSR_DAEMON=True;./awsr

then run this export AWSR_CLIENT=True; ../aws-cli-repl/awsr ec2 describe-instances

Thanks but didn't work. Just hangs. Could you share exactly the steps you used to get this to work? Do you need to insall awscli via pip? Mine is currently installed via manual install from AWS.

@matt-horwood-mayden
Copy link

you have to run the first command in 1 terminal and the second in a new terminal, as the first acts as a server and the second is the client.

Make sure you have the botocore and awscli installed, I think I may have them installed with pip. I also have the awscli installed with brew

@captainfalcon23
Copy link
Author

Thanks!! I got it working now using python venv. It looks like awscli MUST be installed via pip to work. To be clear, this is what I did:

  1. Create a python venv and activate it
  2. Install awscli using pip into venv
  3. Run following command in terminal 1:
export AWSR_DAEMON=True;./awsr --profile XXX
  1. Run following command in terminal 2 to test:
./awsr ec2 describe-instances

I can see this simple command is already performing 5x faster! .2s compared to 1s.

@gaul gaul closed this as completed Oct 9, 2023
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

3 participants