[vim/vim] When saving a file, get warning "Could not set security context for ..." for the corresponding file in undodir directory (#7864)

31 views
Skip to first unread message

Mohammad

unread,
Feb 18, 2021, 8:37:51 AM2/18/21
to vim/vim, Subscribed

Describe the bug
I am using "set undodir" in my .vimrc. When I save a file in Vim, I get this warning message:
"Could not set security context for [home address]/.vim/undodir/[filename]. Press ENTER or type command to continue".

After a ~1 sec delay I can continue by pressing a key. This is annoying as it happens every time I save a file in Vim. The file saving and undodir work as they have to, so I just don't want to receive this warning.

To Reproduce
Detailed steps to reproduce the behavior:

  1. Open a file with Vim
  2. edit
  3. save

Expected behavior
No warnings.

Screenshots
Screen Shot 2021-02-18 at 12 55 59 PM

Environment (please complete the following information):

  • Vim version: VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Dec 15 2020 16:44:08)
  • OS: CentOS Linux; Version: 7 (Core)
  • Terminal: "xterm-256color" [result of "echo $TERM" in terminal]

Additional context
I am connecting with SSH to a remote computer.
The problem exist regardless of saving a new or existing file.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Christian Brabandt

unread,
Feb 18, 2021, 9:28:30 AM2/18/21
to vim/vim, Subscribed

what filesystem is this? Please try with an updated vim 8.2. Also please show the complete :version output.

Mohammad

unread,
Feb 18, 2021, 10:11:02 AM2/18/21
to vim/vim, Subscribed

what filesystem is this? Please try with an updated vim 8.2. Also please show the complete :version output.

Thanks, since I am ssh'ing to a remote computer in which I am a user, I don't have permission to update VIM. I can do it on my local directory but if it this problem is solvable without updating, it would be much better.

The file system is CephFS kernel client. Please note that there is an NFS (nfs_t context) filesystem on the same computer which does not have this problem!

$vim --version


VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Dec 15 2020 16:44:08)

Included patches: 1-207, 209-629
Modified by bugz...@redhat.com
Compiled by bugz...@redhat.com
Huge version without GUI. Features included (+) or not (-):
+acl +farsi +mouse_netterm +syntax
+arabic +file_in_path +mouse_sgr +tag_binary
+autocmd +find_in_path -mouse_sysmouse +tag_old_static
-balloon_eval +float +mouse_urxvt -tag_any_white
-browse +folding +mouse_xterm -tcl
++builtin_terms -footer +multi_byte +terminfo
+byte_offset +fork() +multi_lang +termresponse
+cindent +gettext -mzscheme +textobjects
-clientserver -hangul_input +netbeans_intg +title
-clipboard +iconv +path_extra -toolbar
+cmdline_compl +insert_expand +perl +user_commands
+cmdline_hist +jumplist +persistent_undo +vertsplit
+cmdline_info +keymap +postscript +virtualedit
+comments +langmap +printer +visual
+conceal +libcall +profile +visualextra
+cryptv +linebreak +python/dyn +viminfo
+cscope +lispindent -python3 +vreplace
+cursorbind +listcmds +quickfix +wildignore
+cursorshape +localmap +reltime +wildmenu
+dialog_con -lua +rightleft +windows
+diff +menu +ruby/dyn +writebackup
+digraphs +mksession +scrollbind -X11
-dnd +modify_fname +signs -xfontset
-ebcdic +mouse +smartindent -xim
+emacs_tags -mouseshape -sniff -xsmp
+eval +mouse_dec +startuptime -xterm_clipboard
+ex_extra +mouse_gpm +statusline -xterm_save
+extra_search -mouse_jsbterm -sun_workshop -xpm
system vimrc file: "/etc/vimrc"
user vimrc file: "$HOME/.vimrc"
2nd user vimrc file: "~/.vim/vimrc"
user exrc file: "$HOME/.exrc"
fall-back for $VIM: "/etc"
f-b for $VIMRUNTIME: "/usr/share/vim/vim74"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H -O2 -g -pipe -Wall -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -D_FILE_OFFSET_BITS=64 -D__linux__ -D_REENTRANT -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: gcc -L. -Wl,-z,relro -fstack-protector -rdynamic -Wl,-export-dynamic -Wl,--enable-new-dtags -Wl,-rpath,/usr/lib64/perl5/CORE -Wl,-z,relro -L/usr/local/lib -Wl,--as-needed -o vim -lm -lnsl -lselinux -lncurses -lacl -lattr -lgpm -ldl -Wl,--enable-new-dtags -Wl,-rpath,/usr/lib64/perl5/CORE -fstack-protector -L/usr/lib64/perl5/CORE -lperl -lresolv -lnsl -ldl -lm -lcrypt -lutil -lpthread -lc

K.Takata

unread,
Feb 18, 2021, 5:57:50 PM2/18/21
to vim/vim, Subscribed

I can do it on my local directory but if it this problem is solvable without updating, it would be much better.

There is nothing we can do here if the problem has been solved in the latest version.
I close this for now. Please reopen if it is reproduced on the latest version.

K.Takata

unread,
Feb 18, 2021, 5:57:51 PM2/18/21
to vim/vim, Subscribed

Closed #7864.

Reply all
Reply to author
Forward
0 new messages