07-19-2019
debugfs with its unlink and rm commands comes to mind, but it might suffer from the same problems as the other tools. When using it, be very careful and know exactly what you are doing!
5 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
when i try to ls -lrt the directory, the "undeletable" file is listed.
but when i try to ls -lrt *exe, the "undeletable" file is not listed.
this "undeletable" is the file that i want to delete from the directory.
but when i try to delete/rename/copy.... it, it show that "No such file or... (10 Replies)
Discussion started by: chxxangie
10 Replies
2. UNIX for Dummies Questions & Answers
I've some files created by a script.
For some reason last time the script run was interrupted for an error and the files produced by the script are undeletable.
i've tryed as root with command 'rm' and even if i got no error in command execution the files are still there.
These are the... (9 Replies)
Discussion started by: mirrorx
9 Replies
3. Shell Programming and Scripting
Hi Friends,
I'm a great fan of this forum... it has helped me tone my skills in shell scripting. I have a challenge here, which I'm sure you guys would help me in achieving...
File A has a list of job ids and I need to compare this with the File B (*.log) and File C (extend *.log) and copy... (6 Replies)
Discussion started by: asnandhakumar
6 Replies
4. Shell Programming and Scripting
Hi,
I need to compare 2 text files with around 60000 rows and 1 column. I need to compare these and write the mismatch data to 3rd file.
File1 - file2 = file3
wc -l file1.txt
58112
wc -l file2.txt
55260
head -5 file1.txt
101214200123
101214700300
101250030067
101214100500... (10 Replies)
Discussion started by: Divya Nochiyil
10 Replies
5. Shell Programming and Scripting
Shell script logic
Hi
I have 2 input files like with file 1 content as (file1)
"BRGTEST-242" a.txt "BRGTEST-240" a.txt "BRGTEST-219" e.txt
File 2 contents as fle(2)
"BRGTEST-244" a.txt "BRGTEST-244" b.txt "BRGTEST-231" c.txt "BRGTEST-231" d.txt "BRGTEST-221" e.txt
I want to get... (22 Replies)
Discussion started by: pottic
22 Replies
LEARN ABOUT SUSE
debugfs_create_file
DEBUGFS_CREATE_FILE(9) The debugfs filesystem DEBUGFS_CREATE_FILE(9)
NAME
debugfs_create_file - create a file in the debugfs filesystem
SYNOPSIS
struct dentry * debugfs_create_file(const char * name, mode_t mode, struct dentry * parent, void * data,
const struct file_operations * fops);
ARGUMENTS
name
a pointer to a string containing the name of the file to create.
mode
the permission that the file should have.
parent
a pointer to the parent dentry for this file. This should be a directory dentry if set. If this paramater is NULL, then the file will
be created in the root of the debugfs filesystem.
data
a pointer to something that the caller will want to get to later on. The inode.i_private pointer will point to this value on the open
call.
fops
a pointer to a struct file_operations that should be used for this file.
DESCRIPTION
This is the basic "create a file" function for debugfs. It allows for a wide range of flexibility in creating a file, or a directory (if
you want to create a directory, the debugfs_create_dir function is recommended to be used instead.)
This function will return a pointer to a dentry if it succeeds. This pointer must be passed to the debugfs_remove function when the file is
to be removed (no automatic cleanup happens if your module is unloaded, you are responsible here.) If an error occurs, NULL will be
returned.
If debugfs is not enabled in the kernel, the value -ENODEV will be returned.
COPYRIGHT
Kernel Hackers Manual 2.6. July 2010 DEBUGFS_CREATE_FILE(9)