システムメールボックスを削除できません。

システムメールボックスを削除できません。

UbuntuでPostfixを実行している間、あるアカウントからいくつかのテストメールを受け取りusr1ました。しかし、「delete#」と「delete#」を一緒に使用して削除しようとするたびにd #何も起こりません。

例:

usr1@usr1:~$ mail  
"/var/mail/usr1": 5 messages 5 unread  
>U   1 usr2              Tue Apr 30 15:54  19/478   Testing local mail  
U   2 Mail Delivery Syst Tue Apr 30 15:54  78/2433  Undelivered Mail Returned to Sender
U   3 usr2               Tue Apr 30 15:55  19/614   Re: Testing local mail
U   4 usr2               Tue Apr 30 15:55  19/604   Re: Testing local mail
U   5 Mail Delivery Syst Tue Apr 30 15:55  73/2219  Undelivered Mail Returned to Sender
? d 1-5
? x

usr1@usr1:~$ mail
"/var/mail/usr1": 5 messages 5 unread
>U   1 usr2              Tue Apr 30 15:54  19/478   Testing local mail
U   2 Mail Delivery Syst Tue Apr 30 15:54  78/2433  Undelivered Mail Returned to Sender
U   3 usr2               Tue Apr 30 15:55  19/614   Re: Testing local mail
U   4 usr2               Tue Apr 30 15:55  19/604   Re: Testing local mail
U   5 Mail Delivery Syst Tue Apr 30 15:55  73/2219  Undelivered Mail Returned to Sender
? x

なぜこれを説明できる人がいますか?別のUnix SE投稿(もちろんSolarisで)動作したいので、そのコマンドを使用することについて話していますが、これらのメッセージが削除を拒否する理由を理解できません。

ベストアンサー1

多くの調査の終わりに、私はいつもorをmail使わないことが問題であることに気づきました。 ~からexitxUbuntuのマニュアルページ:

exit (ex or x) Effects an immediate return to the shell without modifying 
               the user's system mailbox, his mbox file, or his edit
               file in -f.

d *したがって、電子メールを削除したりなどを使用したい場合は、必ずを使用または発信する必要がd 1-5あります。mailquitq

これが他人の混乱を和らげてくれることを願っています。

おすすめ記事