# root login sources dead.letter file

## fantasma13

Hi,

this is really strange, but starting today root login starts to source the dead.letter file, which really shouldn't happen. I am clueless where this comes from, there is no reference to the file anywhere in .profile or .bashrc!

Any hints?

----------

## ferreirafm

Hi fantasma13,

Check your crontab schedules (crontab -e). Crontab usually fires a dead.letter file at the end of a task. However, I don't know which programs else behave like this. If it were the case, see the crontab manuals to unset the dead.letter record.

G'Luck

ferreirafm

----------

## fantasma13

 *ferreirafm wrote:*   

> Hi fantasma13,
> 
> Check your crontab schedules (crontab -e). Crontab usually fires a dead.letter file at the end of a task. However, I don't know which programs else behave like this. If it were the case, see the crontab manuals to unset the dead.letter record.
> 
> G'Luck
> ...

 

Ok, but why is it sourced at login and tries to execute its content? That is what bugs me, and honestly, I consider it quite dangerous!

----------

## ferreirafm

fantasma13,

If I understood you question, the vixie-cron daemon is started by its rc scripts (see /etc/init.d). That's a good way to know if cron is really causing this problem. Delete your dead.letter, remove your vixie-cron script from the rc scripts and restart your box afterwards.

```
>rc-update del vixie-cron 
```

Look for the dead.letter file in the same place. If it still was there, crontab is not your problem and you are going to to figure out which program is guilt. Otherwise, as I wrote above, revise your crontab entries.

G'Luck,

ferreirafm

----------

## fantasma13

No, my problem is that root executes the dead.letter file at login, NOT its existence!

----------

## Ant P.

Does it do it from only a login shell or when you su too? Try "bash -v" which will echo every line of script it's running at startup, that should give you some idea of where this file's getting run from.

----------

## fantasma13

 *Ant_P wrote:*   

> Does it do it from only a login shell or when you su too? Try "bash -v" which will echo every line of script it's running at startup, that should give you some idea of where this file's getting run from.

 

Everytime, even with su. I can try that on monday. So you mean doing bash -v as user, then su? Strangely enough it does not do it when doing su as root.

I did mess around with eselect bashcomp, when it started happening, if that helps. But I cannot be sure this is related.

----------

## Bircoph

Try to start you bash with --noprofile and --norc (add a wrapper to /usr/local/bin to replace the real bash)

If --norc helps, check your ~/.bashrc.

If --noprofile helps, check your ~/.bash_profile, ~/.bash_login, ~/.profile, /etc/profile.

If nothing above helps check your /etc/bash/*

----------

## fantasma13

for some reason I had a link to dead.letter in ~/.bash_completion.d/

Now I wonder where this comes from.

----------

