Reputation
324
Top tag
Next privilege 500 Rep.
Access review queues
Badges
1 12
Impact
~18k people reached

  • 0 posts edited
  • 0 helpful flags
  • 31 votes cast
Aug
26
comment Solaris 10 sendmail won't execute my program in /etc/aliases without setuid root
I have never used Solaris before, but I think sudo is something that can be handy for your problem unprivileged_user ALL=(root) NOPASSWD: privileged_command
Aug
26
accepted debian bash/sh string execution
Aug
26
answered debian bash/sh string execution
Aug
24
comment debian bash/sh string execution
That's also my problem... :( As you can see it works if its commented out, so there should be no syntax problem inside the script. But thanks anyway! As I don't have much time this weekend, I will search again next Monday.
Aug
24
revised debian bash/sh string execution
Updated the script
Aug
24
comment debian bash/sh string execution
No there is no space. This is somethign I would have recognized. (I updated my original post to show you what i have done
Aug
24
comment debian bash/sh string execution
Now i get a Syntax error: "(" unexpected (expecting "fi") on your line remote_cmd=(/usr/bin/ssh "$BACKUP_USER@$HOST_TO" "$RENAME_STRING")
Aug
24
comment debian bash/sh string execution
IS working on the command line directly, but not inside a script. remote_cmd="(/usr/bin/ssh $BACKUP_USER@$HOST_TO $RENAME_STRING)" and in the next line "${remote_cmd[@]}" I get a "Bad substitution" Error for the last line... (so eval is still in use...)
Aug
23
revised debian bash/sh string execution
Updated/improved while loop
Aug
23
comment debian bash/sh string execution
@DennisWilliamson you mean especially point 3 ? as i have some trouble executing ssh someuser@somehost < $TEST inside shell script? And <<< as suggested in one answer also doesn't work...
Aug
23
comment debian bash/sh string execution
Thanks for the response, but I understanding the script is not the problem. In fact Security an manageability IS one goal t archive. I know its not one of the best scripts, but thats why I'm here ;) I just thought of to create just one script, which could be easily ported to other/new hosts. Maybe you are right an I should over think the concept. So you mean that I should create script and call it with all necessary variables like $DATASTORE_NAME and $MAX_SNAPSHOTS would also be ok, now as I think of it. Any other suggestion why this would be good/bad?
Aug
23
revised debian bash/sh string execution
Added a line
Aug
23
revised debian bash/sh string execution
Again an update
Aug
23
comment debian bash/sh string execution
@val0x00ff I just updated my Post. How do you mean I should solve it to be "correct"?
Aug
23
revised debian bash/sh string execution
UPDATE and typo corrention
Aug
23
comment debian bash/sh string execution
@val0x00ff Your suggestion didn't work, or did you mean something else? eval actualy worked (like in the answer from dsumsky)
Aug
23
comment debian bash/sh string execution
Thanks! I rely never stumbled upon this problem till now. Thanks again!
Aug
23
revised debian bash/sh string execution
missed out to format something
Aug
23
asked debian bash/sh string execution
Aug
23
comment SSH timeouts between hosts which are connected via multiple routes
@StefanZimmermann Additional: Is there any good reason for this setup? I just cant figure out a way why SSH could not just listen ob both IPs?