General :: Remove Noexec From Temp Directory?
Nov 17, 2009How do I remove the noexec from the tmp directory, temporarily?
View 3 RepliesHow do I remove the noexec from the tmp directory, temporarily?
View 3 RepliesI have a web server whos DocumentRoot is:/tmp/wwwNow, /temp/www/fake/ is a directory that contains a series of other files/folders.What I want to do is access the files in /temp/www/fake as if they were in the root directory (/temp/www/)For example:
could either be located in "/temp/www/test.php"
-or-
located in "/temp/www/fake/test.php"
so "http://127.0.0.1/test.php" would essentially call both directories. Is this possible? Whould I do this through apache or through the actual file system somehow? (Like some sort of symbolic link?) I would love to hear your input.
On Debian Standard System I would like to is change /tmp directory from it's original /dev/hda8 to destination /dev/hdd5
Code:
Disk /dev/hda: 6448 MB, 6448619520 bytes
255 heads, 63 sectors/track, 784 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
[code]...
If I change /dev/hda8 to /dev/hdd5 and reboot the startx command fails to run.
I just realized that my /tmp directory is not being cleared at shutdown time. How to enable this? I'm running -current.
View 8 Replies View RelatedRecently I was downloading a file from within Firefox when the Internet connection was lost. Where should I look to find the partial file? I want to delete it.
View 3 Replies View RelatedRHEL 5 is my proxy server. i want to remove temp files and cache . How do i remove cache and temp files.
View 3 Replies View RelatedI have udev rules that creates a directory for each usb-media that is plugged into my debian to automount usb-media. This directory where mount-points (the mount-directories) are created is passed through a rdp-connection with rdesktop. On our terminalserver there's a drive Z that shows all mount-points with content of usb-media.When users remove usb-media, udev unmounts usb-media and tries to delete the directory that was used to mount usb-media.If the users hasn't closed explorer showing any subfolder of usb-media, the unmount-command succeeds but the rmdir-command fails because the ressource is "busy or used".My question: how can I force to delete this mountpoint? (rmdir doesn't have force and rm -rf doesn't work)Edit: I should add, that I can't use third-party software or additional packages because the linux-machine is a thin-client with very low disk-space.
View 1 Replies View Relatedi have a hacking attack on my server where some one tried to implement shell and scripts,
also in a directory he placed a symbolic link to my root. i tried to remove it with rm directotyname but it gave me :
> rm directotyname
rm: cannot remove directory `directotyname': Is a directory
how can i remove the symbolic link and make sure it will not happen again ?
ubuntu@ubuntu:/usr/lib/locale$ sudo rm -R nl_NL.utf8 rm: cannot remove directory `nl_NL.utf8': Input/output error I'm having problems deleting a seemingly corrupted directory to allow for a reconfiguration of this locale, but the OS doesn't let me do it. Why?
View 2 Replies View RelatedI'm trying to tar a collection of files in a directory called 'my_directory' and remove the originals by using the command:
tar -cvf files.tar my_directory --remove-files
However it is only removing the individual files inside the directory and not the directory itself (which is what I specified in the command). What am I missing here?
I have a folder with many many files. e.g html, docs, excel sheet, script etc.
Now I want to find {using grep command}a certain word in that folder/directory and delete it in all the files and scripts that have it.
For example, I want to delete the word /testing (with the slash) in all files in a directory.
I have a WD external disk, NTFS file system. I mounted it on my Red Hat. While on the external disk, I deleted a directory, which was sent to .Trash-root of that disk.I went to .Trash-root and did rm -rf to completely delete that directory, but I got the following error: cannot remove `<directory>': Input/output errorWhen I do ls -la on that directory that I wish to remove, it shows me it has 0 files inside. But not only I can't remove it, I can't do anything else with it (copy, etc). And I have all the rights on that directory, so this isn't the problem.
View 6 Replies View RelatedI would like to create a cronjob that will delete all files within a directory 1 hours after it is created to the folderI found this cron find /path/to/file/* -ctime +1 -exec rm {} ; but it's deleted all files.I want to make an exception, all file should be deleted except one file (letsay file a.zip)
View 16 Replies View RelatedIf /tmp and /dev/shm partitions are mounted with the noexec flag then this prevents someone from executing something in those partitions.
Example:
You will get permission denied
However if you execute that same script like this:
Then the script gets executed which makes the noexec flag useless.
If there any way to prevent this bug/vulnerability?
I'm able to use the following to remove the target directory and recursively all of its subdirectories and contents. find '/target/directory/' -type d -name '*' -print0 | xargs -0 rm -rf
However, I do not want the target directory to be removed. How can I remove just the files in the target, the subdirectories, and their contents?
how to write a script so that when I use the 'del' command it removes/sends the files / folders to a I specify for example 'dustbin'
View 1 Replies View Relatedhow do i remove it?
View 4 Replies View RelatedI have two questions:How do I remove files from Directory A if their name appears in Directory B?How do I move foo.jpg and bar.jpg from Directory C to Directory D if and only if foo.png and bar.png appear in Directory D?I suspect there's probably a bash one-liner for this, but...I can't come up with it.
View 5 Replies View RelatedI want to remove the index.html file alone in the every directory via bash script, for example i have 5 directories in the path /var/www/vhost
anish
kumar
linux
question
friend
each directories have index.html file now i want to replace the index.html file alone from the other directory /var/tmp/vhosbak
anish
kumar
linux
question
friend
How we can do this using script?
Whenever I plug an external harddrive to a CentOS system,all partitions mounted will have noexec that makes my binaries or script files not executable.
Quote:
[root@centos52-64-dell ~]# mount
/dev/sda3 on / type ext3 (rw)
proc on /proc type proc (rw)
sysfs on /sys type sysfs (rw)
[code]....
I have to remount it using, e.g.,
mount -o remount,exec /dev/sdb1
But I am sick and tired of doing it everyday. What I can I do ?I don't want to use /etc/fstab to solve this problem becauseit will cause booting problem (curable though) when the hard drive is not around.
How to change the default noexec when an external hard drive is plug to CentOS through usb ?
View 4 Replies View RelatedSo I mounted an ISO of MEPIS 11 in /mnt/temp, having understood that I can access the files. Well, no, I can't--not really. Almost all the files in the distro are part of the 1.2 GB "mepis" file that comprises the bulk of what's in the iso. I thought I would be able to look inside the distro's guts if I mounted the iso, which would probably have been helpful in explaining why my remastered copies of the ISO weren't any smaller even after I removed a large amount of the applications. (I wanted to modify MEPIS 11 to make it fit onto a CD.) If I can't do this, what is the practical use of mounting the iso and looking at the files?
View 2 Replies View RelatedI am attempting to setup linux in my embedded environment. I wanted to output the console display though the tty serial port and the vt. Since I don't have a frambuffer hw driver yet, I just wanted to use the vfb as a temp.
So, this is what I did in my configuration file:
CONFIG_CMDLINE="console=ttyS0,115200n8 console=tty0 mem=126M video=vfb:"
CONFIG_VT=y
CONFIG_FB=y
CONFIG_FB_VIRTUAL=y
CONFIG_DUMMY_CONSOLE=n
CONFIG_FRAMEBUFFER_CONSOLE=y
CONFIG_VGA_CONSOLE=n
I would expect the tty output to go to the uart as well as the virtual-console; this does not seem to be the case, as no vt functions are called when I execute prompt commads - I can see the console in my serial terminal, and this all works fine.
Here are extracts from my boot:
Kernel command line: console=ttyS0,115200n8 console=tty0 mem=126M video=vfb:
...
Console: colour dummy device 80x30
console [tty0] enabled
...
Console: switching to colour frame buffer device 80x25
fb0: Virtual frame buffer device, using 1024K of video memory
Serial: 8250/16550 driver, 4 ports, IRQ sharing disabled
serial8250.0: ttyS0 at MMIO 0x3e000000 (irq = 99) is a 16550A
console [ttyS0] enabled
serial8250.0: ttyS1 at MMIO 0x3e001000 (irq = 9 is a 16550A
serial8250.0: ttyS2 at MMIO 0x3e002000 (irq = 97) is a 16550A
...
Here are my console binding results:
/ #
cat /sys/class/vtconsole/vtcon0/bind
0
/ # cat /sys/class/vtconsole/vtcon0/name
(S) dummy device
/ # cat /sys/class/vtconsole/vtcon1/bind
1
/ # cat /sys/class/vtconsole/vtcon1/name
(M) frame buffer device
/ #
i am trying to delete temp files using rm -rf but i am getting this error "bash: /usr/bin/rm: Arg list too long"
View 11 Replies View Relatedwe have 2 linux desktop m/c as server and we use amc n windows as clients....we get more temp files like .AppleDoueble, ":2edstore".i need to remove these temp files periodically with the script. how to write a script to remove these temp files.....
View 8 Replies View RelatedI have an K10 AMD CPU and unfortunately it has a borked temp sensor. I have figured out that if I subtract 8 from value stored in /proc/acpi/thermal_zone/temperature that the result is very close to being spot on. The problem is I have no idea to do this and conky has no built in way to do this.
The data stored in /proc/acpi/thermal_zone/temperature looks like this:
Code:
temperature: 52 C
Is there some sort of script that can do this?
How to find the filesize of a flash which is not exactly stored in the temp but redirected by a fd.
flash31 -> /tmp/FlashXXvsg1uY (deleted) directory is /proc/processid
Chrome is downloading a flash and I can see in the proc directory the flash file, How can I see the current file size of such a file ?
I Downloaded tomcat6 core and uncompressed using the tar utility and the result was apache-tomcat-6.0.32.Now want to remove it.When going through the Graphical mode to the Downloads directory and try to delete it it says permission denied.When trying to use the rmdir command as root the message is that the directory is not empty.How to remove a directory which has many files in it from the command line or through the graphical mode to which normally the message you get is permission denied ?
View 6 Replies View RelatedI am still a novice with Ubuntu and I am trying to write a shell script which will clean redundant files. I am stuck with one line where I would need a command which will remove all files from directory except some of them. Can anyone please advice how to add such an exception to the rm command? I have searched some bash shell tutorials, however, no joy. Guess I have overlooked something.
View 9 Replies View RelatedI was preparing a script which will remove all my files from directory which are 24 hour old.I tried some thing like thisfind . ( -name 'log.*' -mtime +1 ) -exec rm {}; but it is throughing error like : missing argument to exec.
View 8 Replies View Related