Re: [minor] umask 400 causes here-{doc,string} failure

2018-03-12 Thread Greg Wooledge
On Sun, Mar 11, 2018 at 03:17:42PM +, Stephane Chazelas wrote: > I can think of several ways to address it: > > 1- do nothing and blame the user as the user explicitly asked > for files to be unreadable This one gets my vote. That umask is just entirely wrong. Did the user really mean 0377

Loop on mysql output with bash

2018-03-12 Thread Boubaker Idir
Hello everybody, I need to do a loop on my mysql output (packetid) and put it everytime on the second SELECT command, to have a result for each packetid and put it everytime on text file. can you help me please? Thank you so much #!/bin/bash array=$(mysql -u root -pMyPassword -s -N

Loop on mysql output with bash

2018-03-12 Thread Boubaker Idir
Hello everybody, I need to do a loop on my mysql output (packetid) and put it everytime on the second SELECT command, to have a result for each packetid and put it everytime on text file. can you help me please? Thank you so much #!/bin/bash array=$(mysql -u root -pMyPassword -s -N

Loop on mysql output with bash

2018-03-12 Thread Boubaker Idir
Hello everybody, I need to do a loop on my mysql output (packetid) and put it everytime on the second SELECT command, to have a result for each packetid and put it everytime on text file. can you help me please? Thank you so much #!/bin/bash array=$(mysql -u root -pMyPassword -s -N

Re: Loop on mysql output with bash

2018-03-12 Thread Chet Ramey
On 3/12/18 12:42 PM, Boubaker Idir wrote: > Hello everybody, I need to do a loop on my mysql output (packetid) and put it > everytime on the second SELECT command, to have a result for each packetid > and put it everytime on text file. can you help me please? Thank you so much This might be bett

Avoiding file-based constraints for tmp files (ws Re: [minor] umask 400 causes here-{doc,string} failure)

2018-03-12 Thread L A Walsh
Stephane Chazelas wrote: $ bash -c 'umask 400; cat <<< test' bash: cannot create temp file for here-document: Permission denied ... I can think of several ways to address it: --- Another way to address it (with env-based limits for instance + sum): If using less than env-mem limits for her

Re: Avoiding file-based constraints for tmp files (ws Re: [minor] umask 400 causes here-{doc,string} failure)

2018-03-12 Thread Eduardo Bustamante
On Mon, Mar 12, 2018 at 2:05 PM, L A Walsh wrote: [...] > What would be the downside(s) of such an implementation? There's code out there that relies on several properties of regular files, one of them for example, that you can seek on them. I recommend against any change to here documents and he