Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
archivemail permission problem
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
carpman
Advocate
Advocate


Joined: 20 Jun 2002
Posts: 2202
Location: London - UK

PostPosted: Sat May 26, 2007 2:36 pm    Post subject: archivemail permission problem Reply with quote

Hello, tried running archivemail but it fails with what looks like a permission problem?


Code:

archivemail -d465 -s '' -o /home/mail-bak /home/sara/.maildir/.*
Traceback (most recent call last):
  File "/usr/bin/archivemail", line 1298, in ?
    main()
  File "/usr/bin/archivemail", line 619, in main
    archive(mailbox_path)
  File "/usr/bin/archivemail", line 1042, in archive
    _archive_dir(mailbox_name, final_archive_name, "maildir")
  File "/usr/bin/archivemail", line 1188, in _archive_dir
    archive.finalise()
  File "/usr/bin/archivemail", line 542, in finalise
    shutil.copy2(self.mbox_file_name, final_name)
  File "/usr/lib/python2.4/shutil.py", line 92, in copy2
    copyfile(src, dst)
  File "/usr/lib/python2.4/shutil.py", line 48, in copyfile
    fdst = open(dst, 'wb')
IOError: [Errno 13] Permission denied: '/home/mail-bak/..gz'



This was run as root, the dir /home/mail-bak is owned by root?

any ideas?

cheers
_________________
Work Station - 64bit
Gigabyte GA X48-DQ6 Core2duo E8400
8GB GSkill DDR2-1066
SATA Areca 1210 Raid
BFG OC2 8800 GTS 640mb
--------------------------------
Notebook
Samsung Q45 7100 4gb
Back to top
View user's profile Send private message
magic919
Advocate
Advocate


Joined: 17 Jun 2005
Posts: 2182
Location: Berkshire, UK

PostPosted: Sat May 26, 2007 7:21 pm    Post subject: Reply with quote

Try running the dry run version and gradually adding the switches until you find what is breaking it.
Back to top
View user's profile Send private message
carpman
Advocate
Advocate


Joined: 20 Jun 2002
Posts: 2202
Location: London - UK

PostPosted: Sun May 27, 2007 8:23 am    Post subject: Reply with quote

magic919 wrote:
Try running the dry run version and gradually adding the switches until you find what is breaking it.


dry run works fine and says what it will, it only fails on actual run?


tried it with less switches

Code:

archivemail -d465  -o /home/mail-bak /home/sara/.maildir/.*


but still the same?


it seem that it fails when creating the actual archive?
_________________
Work Station - 64bit
Gigabyte GA X48-DQ6 Core2duo E8400
8GB GSkill DDR2-1066
SATA Areca 1210 Raid
BFG OC2 8800 GTS 640mb
--------------------------------
Notebook
Samsung Q45 7100 4gb
Back to top
View user's profile Send private message
magic919
Advocate
Advocate


Joined: 17 Jun 2005
Posts: 2182
Location: Berkshire, UK

PostPosted: Sun May 27, 2007 9:05 am    Post subject: Reply with quote

I get errors when I run with that .* on the end on mine. Not the same error you get, but it doesn't like for me.
Back to top
View user's profile Send private message
carpman
Advocate
Advocate


Joined: 20 Jun 2002
Posts: 2202
Location: London - UK

PostPosted: Sun May 27, 2007 10:18 am    Post subject: Reply with quote

magic919 wrote:
I get errors when I run with that .* on the end on mine. Not the same error you get, but it doesn't like for me.



I tried it without .* but then it only does the inbox and not all other mail dir?
_________________
Work Station - 64bit
Gigabyte GA X48-DQ6 Core2duo E8400
8GB GSkill DDR2-1066
SATA Areca 1210 Raid
BFG OC2 8800 GTS 640mb
--------------------------------
Notebook
Samsung Q45 7100 4gb
Back to top
View user's profile Send private message
magic919
Advocate
Advocate


Joined: 17 Jun 2005
Posts: 2182
Location: Berkshire, UK

PostPosted: Sun May 27, 2007 10:34 am    Post subject: Reply with quote

Yep. That's what I found. I'm not sure it's smart enough to do the recursing on its own. You'll have to cook up a script to run archivemail I think.
Back to top
View user's profile Send private message
carpman
Advocate
Advocate


Joined: 20 Jun 2002
Posts: 2202
Location: London - UK

PostPosted: Sun May 27, 2007 8:43 pm    Post subject: Reply with quote

magic919 wrote:
Yep. That's what I found. I'm not sure it's smart enough to do the recursing on its own. You'll have to cook up a script to run archivemail I think.



Ok have found that dir that archive is being created in must be writable by the users who mail is being archived, i thought that it was needed by user who was running script?

Recursive /.* works fine but you end up with archive for each mail dir in users .maildir but that is fine, in fact it is good :)
_________________
Work Station - 64bit
Gigabyte GA X48-DQ6 Core2duo E8400
8GB GSkill DDR2-1066
SATA Areca 1210 Raid
BFG OC2 8800 GTS 640mb
--------------------------------
Notebook
Samsung Q45 7100 4gb
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum