Bug 37412 - crontab -e not working when /tmp -> /usr/tmp
Summary: crontab -e not working when /tmp -> /usr/tmp
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: vim
Version: 7.3
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Karsten Hopp
QA Contact: David Lawrence
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2001-04-24 14:17 UTC by Aleksey Nogin
Modified: 2007-04-18 16:32 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2004-10-27 13:10:53 UTC
Embargoed:


Attachments (Terms of Use)

Description Aleksey Nogin 2001-04-24 14:17:47 UTC
crontab -e tells me "crontab: no changes made to crontab" no matter what I
do. Except, if I change /tmp to be a directory instead of being a symlink
to /usr/tmp, it starts working fine.

P.S. I believe this is _not_ a duplicate of bug #25992 since RH 7.1 already
has vim-6.0-0.27.

Comment 1 Ed Voncken 2002-02-17 11:19:21 UTC
This is a VERY irritating bug, and 100% reproducible on RedHat Linux 7.2 with
all errata applied:

[root@r2d2 /]# rpm -qa |grep "^vi"
vim-common-6.0-7.13
vixie-cron-3.0.1-63
vim-enhanced-6.0-7.13
vim-minimal-6.0-7.13

/tmp -> ./var/tmp

I've used 'ls -li' to check the /tmp/crontab.<pid> files while editing crontabs,
and VIM definitely writes the file out using a different inode.

This appears to be the source of the problem; changes are ignored since the
changes were saved to a file with a different inode.

This used to work under lower revisions of RedHat.

Greetings,
  Ed.

Comment 2 Michael Wardle 2002-05-09 02:09:53 UTC
I also have /tmp -> /var/tmp and am seeing this issue on a Red Hat 7.2 box,
however setting EDITOR to something other than vi (such as emacs) makes "crontab
-e" work as expected.  Perhaps vi has problems with temporary files on some systems.


Comment 3 Bill Huang 2002-06-03 09:22:10 UTC
It is a bug of vim.

Comment 4 Aleksey Nogin 2002-06-08 05:35:51 UTC
This problem still exists in 7.3

Comment 5 Aleksey Nogin 2002-06-30 06:55:27 UTC
This problem still exists with vim-6.1-4 and vixie-cron-3.0.1-67 from a recent
Rawhide.

Comment 6 Paul Dyer 2003-06-03 14:37:47 UTC
This is still a bug with RH AS v2.1.   I have /tmp linked to /var/tmp and I
unable to save crontab -e entries.   My workaround is to remove the link, update
my crontab entries, then put the link back.

Please fix this bug.  It is years old.

Comment 7 Need Real Name 2004-10-27 11:02:09 UTC
Should crontab -e edit /etc/crontab by default?

Comment 8 Need Real Name 2004-10-27 11:03:51 UTC
btw bug 90981 seems to have a fix for this

Comment 9 Karsten Hopp 2004-10-27 13:10:53 UTC
tested with the current vim-6.3-029, cannot reproduce it anymore


Note You need to log in before you can comment on or make changes to this bug.