Re: configure /etc/pam.d/crond to use pam_mount
Simone Gaiarin <[email protected]> Sun, 09 Oct 2016 15:09:22 +0000
| Newsgroups | gmane.linux.pam |
|---|---|
| Message-ID | <CAO-ExucYHMWBX1Bn4PqXxi1Ogm_W9+EQgi2dFxgB-SdnDuv7hA@mail.gmail.com> |
--===============1861069240712910009== Content-Type: multipart/alternative; boundary=089e0141ab74df5bca053e700726 --089e0141ab74df5bca053e700726 Content-Type: text/plain; charset=UTF-8 I've just tried now and I manage to list the files even from the cron job. I've tested to take a backup with backintime and that also works fine. Also another problem that I've described here https://sourceforge.net/p/pam-mount/support-requests/61/ is gone. I'm wondering what fixed the issue. I'm sorry to made you lose time. I've spent many months trying to figure out a solution to this annoying problem and now it's just gone by itself. As a reference an extended discussion is present here: https://github.com/bit-team/backintime/issues/590 where I've also posted the results of ls /media/dataHD at the time, and where the result from the cronjob was: /media/dataHD: total 0 Thanks On Sun, Oct 9, 2016 at 4:29 PM Matus UHLAR - fantomas <[email protected]> wrote: On 09.10.16 08:02, Simone Gaiarin wrote: >Short version: Cron jobs cannot access the content of the encrypted disk >even when I'm logged in. I can access the content of the disk from bash or >graphical file explorer. > >Longer version: >I've first seen problem because I'm using backintime to perform automatic >backup of my disk. When I run the backup manually everything is fine, while >when the backup is performed automatically with cron the resulting backup >is always empty. > >Adding the follwing command to crontab (using crontab -e), in order to list >the content of the drive (/media/dataHD), show me that the ls of the drive >doesn't produce any result. > >*/1 * * * * ls -la /media /media/dataHD /media/dataHD/work > /tmp/filelist could you show us the results when run from cron and manually? -- Matus UHLAR - fantomas, [email protected] ; http://www.fantomas.sk/ Warning: I wish NOT to receive e-mail advertising to this address. Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu. Saving Private Ryan... Private Ryan exists. Overwrite? (Y/N) _______________________________________________ Pam-list mailing list [email protected] https://www.redhat.com/mailman/listinfo/pam-list --089e0141ab74df5bca053e700726 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div dir=3D"ltr" class=3D"gmail_msg">I've just tried n= ow and I manage to list the files even from the cron job. I've tested t= o take a backup with backintime and that also works fine. Also another prob= lem that I've described here <a href=3D"https://sourceforge.net/p/pam-m= ount/support-requests/61/">https://sourceforge.net/p/pam-mount/support-requ= ests/61/</a> is gone. I'm wondering what fixed the issue.</div><div><br= ></div><div>I'm sorry to made you lose time. I've spent many months= trying to figure out a solution to this annoying problem and now it's = just gone by itself.</div><div><br></div>As a reference an extended discuss= ion is present here:=C2=A0<a href=3D"https://github.com/bit-team/backintime= /issues/590">https://github.com/bit-team/backintime/issues/590</a><br>where= I've also posted the results of ls /media/dataHD at the time, and wher= e the result from the cronjob was:<div><br></div><div><pre style=3D"box-siz= ing:border-box;font-family:consolas,"liberation mono",menlo,couri= er,monospace;font-size:11.9px;margin-top:0px;font-stretch:normal;line-heigh= t:1.45;word-wrap:normal;padding:16px;overflow:auto;background-color:rgb(247= ,247,247);border-radius:3px;color:rgb(51,51,51);margin-bottom:0px"><code st= yle=3D"box-sizing:border-box;font-family:consolas,"liberation mono&quo= t;,menlo,courier,monospace;font-size:11.9px;padding:0px;margin:0px;backgrou= nd-image:initial;background-position:initial;background-size:initial;backgr= ound-repeat:initial;background-origin:initial;background-clip:initial;backg= round-color:transparent;border-radius:3px;word-break:normal;border:0px;disp= lay:inline;overflow:visible;line-height:inherit;word-wrap:normal">/media/da= taHD: total 0</code></pre><div><br></div>Thanks</div><div><br class=3D"gmail_msg"= ><div class=3D"gmail_quote gmail_msg"><div dir=3D"ltr" class=3D"gmail_msg">= On Sun, Oct 9, 2016 at 4:29 PM Matus UHLAR - fantomas <<a href=3D"mailto= :[email protected]" class=3D"gmail_msg" target=3D"_blank">[email protected]= </a>> wrote:<br class=3D"gmail_msg"></div><blockquote class=3D"gmail_quo= te gmail_msg" style=3D"margin:0 0 0 .8ex;border-left:1px #ccc solid;padding= -left:1ex">On 09.10.16 08:02, Simone Gaiarin wrote:<br class=3D"gmail_msg">= <br>>Short version: Cron jobs cannot access the content of the encrypted= disk<br class=3D"gmail_msg"><br>>even when I'm logged in. I can acc= ess the content of the disk from bash or<br class=3D"gmail_msg"><br>>gra= phical file explorer.<br class=3D"gmail_msg"><br>><br class=3D"gmail_msg= "><br>>Longer version:<br class=3D"gmail_msg"><br>>I've first see= n problem because I'm using backintime to perform automatic<br class=3D= "gmail_msg"><br>>backup of my disk. When I run the backup manually every= thing is fine, while<br class=3D"gmail_msg"><br>>when the backup is perf= ormed automatically with cron the resulting backup<br class=3D"gmail_msg"><= br>>is always empty.<br class=3D"gmail_msg"><br>><br class=3D"gmail_m= sg"><br>>Adding the follwing command to crontab (using crontab -e), in o= rder to list<br class=3D"gmail_msg"><br>>the content of the drive (/medi= a/dataHD), show me that the ls of the drive<br class=3D"gmail_msg"><br>>= doesn't produce any result.<br class=3D"gmail_msg"><br>><br class=3D= "gmail_msg"><br>>*/1 * * * * ls -la /media /media/dataHD /media/dataHD/w= ork > /tmp/filelist<br class=3D"gmail_msg"><br><br class=3D"gmail_msg"><= br>could you show us the results when run from cron and manually?<br class= =3D"gmail_msg"><br><br class=3D"gmail_msg"><br>--<br class=3D"gmail_msg"><b= r>Matus UHLAR - fantomas, <a href=3D"mailto:[email protected]" class=3D"gma= il_msg" target=3D"_blank">[email protected]</a> ; <a href=3D"http://www.fan= tomas.sk/" rel=3D"noreferrer" class=3D"gmail_msg" target=3D"_blank">http://= www.fantomas.sk/</a><br class=3D"gmail_msg"><br>Warning: I wish NOT to rece= ive e-mail advertising to this address.<br class=3D"gmail_msg"><br>Varovani= e: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.<br class=3D"gm= ail_msg"><br>Saving Private Ryan...<br class=3D"gmail_msg"><br>Private Ryan= exists. Overwrite? (Y/N)<br class=3D"gmail_msg"><br><br class=3D"gmail_msg= "><br>_______________________________________________<br class=3D"gmail_msg= "><br>Pam-list mailing list<br class=3D"gmail_msg"><br><a href=3D"mailto:Pa= [email protected]" class=3D"gmail_msg" target=3D"_blank">[email protected]= m</a><br class=3D"gmail_msg"><br><a href=3D"https://www.redhat.com/mailman/= listinfo/pam-list" rel=3D"noreferrer" class=3D"gmail_msg" target=3D"_blank"= >https://www.redhat.com/mailman/listinfo/pam-list</a><br class=3D"gmail_msg= "><br></blockquote></div></div></div> --089e0141ab74df5bca053e700726-- --===============1861069240712910009== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Pam-list mailing list [email protected] https://www.redhat.com/mailman/listinfo/pam-list --===============1861069240712910009==--