Solution to Textfilebusy prompt during program execution in Linux

Source: Internet
Author: User
Recently, Textfilebusy was prompted when running commands in linux. Baidu found that the fuserxxx command was used to check which process occupied the file and then shut down the process.

Run the fuser xxx command to check which process occupies the specified file, and then close the process to solve the problem.
Note: If the xxx command is enabled in common root mode, but is used in common users, fuser xxx has no result.
Switch to root usage, and then execute fuser xxx. The process number is displayed and killed.

Eg:
#./Xfbdev: 0-fp/usr/share/fonts/X11/misc
./Xfbdev: Text file busy

$ Fuser Xfbdev
$ Sudo su
# Fuser Xfbdev
Xfbdev: 28784e
# Ps aux | grep Xfbdev
Root 28784 0.9 0.2 4608 2640 pts/0 S +./Xfbdev: 0-fp/usr/share/fonts/X11/misc
Root 30708 0.0 0.1 3792 1248 pts/1 S + grep Xfbdev

Solution to Text file busy

Author: liucy
When using scp to copy files across servers, a Text file busy error occurs, leading to the failure to complete the operation. after searching, we learned that the error indicates that the file is being used by a process, unable to copy because it is locked. After verification, we learned that using the fuser command can solve the above problem. The specific command is as follows:
Fuser-cdkux filename

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.