General :: Reboot Not Required After Changing HOSTS File Content?
Oct 18, 2010
I was having a discussion with someone who asked me whether a Linux OS has to be rebooted when the hosts file is modified. From personal experience, on Windows I change the file but don't reboot and I've seen others do the same thing. I assume Linux has no exception(s), but is there any reason why a reboot is not required (to at least justify my actions)?
View 2 Replies
ADVERTISEMENT
Apr 25, 2011
I want to know why when i change the file hosts, fill it with due parameters and reboot the system, the latter unexpectedly change ?
View 2 Replies
View Related
Aug 4, 2009
I need a script but i am not good at programming soWhat script have to do:- Every 1 minute is checking if ip address is available (ping)- if ip answers nothing happens- if ip does not answers: * file /etc/hosts is changed by one stored in /home/user/hosts* notification by xterm to restart some programIf finally ip answers file /etc/hosts is changed by one stored in /home/user2/hosts
View 6 Replies
View Related
Apr 12, 2011
If you have the value 100 in File1 and the value 5 in File2, how do you write a script to divide the 100 in File1 by the 5 in File2 in Linux Bash Shell?The operating system I am using is Ubuntu 10 and object is to write a script to accomplish this task.
View 5 Replies
View Related
Mar 8, 2010
I have several websites available via both HTTP and HTTPS, with images served from a separate virtual host. This breaks in IE because the images are loaded by the CSS, and because they're in a separate Virtual Host, I have to use absolute paths in the CSS.
Example:
[URL]
Renders in IE like this:
[URL]
The issue being that the wiki.archserver.org is being served via SSL, but the header logo is served by img.archserver.org and the CSS uses the absolute path [URL] to load the logo. So, the only solutions I can see are:
1) Change the CSS to always use SSL. This will slow down the site, increase load on the server and is generally a poor-practise as a "solution"
2) Maintain 2 copies of the CSS, serving a HTTP version to HTTP requests, and HTTPS version to HTTP. This creates a management overhead which is less than desirable.
3) Create an Alias in Apache to send requests for [URL] to [URL] internally then rewriting the CSS to use relative paths.
4) Screw IE; it works in Firefox, Chrome and every other browser AFAIK. The sites are for a Linux project anyway.
View 7 Replies
View Related
Sep 2, 2009
My DVD will not play DVD's. I can only play cd's/music. The drop down box tells me that an additional plugin is required to play the dvd content and do I want to search for this now. Naturally I said yes. The next drop down box says that search could not find plugin in any configured software source. I have been to www.liba52.sourceforge.net and found ; a52dec-0.7.4.tar.gz I'm not too confident about using this, but have it in my 'home' file on the desktop. If anyone thinks it is ok, how to install it. If its not ok, can you tell me how I can obtain the appropriate plugin. I have Fedora 10 installed. The DVD is a Pioneer 104.
View 4 Replies
View Related
May 2, 2011
I'm trying to use ssh-keyscan to get some known_host file population going on, but I have a ton of hosts I want to scan, all with multiple aliases in /etc/hosts. Is there a way to use my current /etc/hosts file to do an ssh-keyscan instead of making a special list of hosts that (from what I've read) ssh-keyscan needs?
View 2 Replies
View Related
Aug 1, 2011
I have installed CrunchBang, then I moved the /tmp and /var to different partitions (I like to put these on reiserfs) the reason I did it after the install is because CrunchBang's installer doesn't give me the options to create reiserfs partitions during install (but does recognise reiserfs as I can manually mount them). Also these two partitions are logical.Anyway I have Windows 7 and Ubuntu 10.04 already installed and working fine but CrunchBang always changes the UUIDs of /var and /tmp when I reboot. Is that even possible I have also tried using the old method of /dev/sd** but of course that gets changed as well.
View 3 Replies
View Related
Jan 26, 2011
Probably an easy (which means stoopid) question...I am trying to reroute a website using my hosts file so that it matches my servers certificate file for testing without effect dns and the live site.When I went to edit my /etc/hosts file it is non-existent. I have, I am assuming in it's place, hosts.allow and hosts.deny. Can anyone explain why I do not have a hosts file?
View 1 Replies
View Related
May 20, 2011
I've 3 hosts images installed in virtualbox, that every time I reboot an image, the ip address change.
The 3 images are ubuntu.
I would like to configure these images in a way that, every time I reboot the images, I can access them by the name, and not by the ip.
View 2 Replies
View Related
May 27, 2011
I'm using rhel6. Using File Browser Nautilus 2.28.4 I could easily locate any file I'm interested in by it name. I'd like to use this File Browser to locate the file name based on it content e.g. based on some word in the text file. It doesn't work for me that way ... My question: does Nautilus support the search of file based on it content or only based on the name of the file itself?
View 4 Replies
View Related
Jul 6, 2010
I have a few partitions on my hard-drive, one for Ubuntu, one for Windows 7 and another for general data storage. When I installed Ubuntu, I was presented with a GUI which allowed me to easily reassign storage space from the latter two to create the former. Is there any way to get to something similar, from which I can adjust the proportions of the partition sizes, without affecting their content?
View 1 Replies
View Related
Jul 13, 2010
I'm facing bit of a conundrum with my new server. It is essentially a distributed-virtual Plesk Virtuoso container with a rather simple LAMP setup (PHP5 etc) and virtual hosting. Running 10.04 LTS.
The issue is that on each reboot, the /etc/hosts and /etc/hostname files are reset with their original configs causing the virtual hosting to break, i.e. rather than hosting the vhosts correctly, it essentially routes all traffic to /var/www, or essentially 000-default ~ this beats the whole point of vhosting in the first place!
Is there any way to get around them being overwritten at boot? A very crude workaround would be to set a script to load at boot via init.d and have it rewrite both files to their correct configs - of course, I have no idea as to the point during boot at which they get replaced.
View 2 Replies
View Related
Nov 10, 2010
i have a file and i want to change the content of file but i also want that md5sum of that file remains same.
View 14 Replies
View Related
Feb 12, 2011
I'm currently administering an Ubuntu box remotely. It's set to install security updates automatically, and it notifies me when I log in via ssh whether it has installed an update which requires a reboot. For example, if it installed a kernel update a few days ago, the update manager will touch a "reboot_required" file in /var/run, and when I ssh into the machine today I'll be greeted with a "System restart required" message. Is there a similar functionality for yum or Packagekit?
View 1 Replies
View Related
Jan 22, 2010
I have a boring, brown, GDM login screen. I'm assuming this is what shows when there are no GDM themes. I don't see any options in Administration -> Login Window, so what do I need to do to get the standard, Ubuntu GDM theme? What package (asides from vanilla GDM) is required for this on Karmic?
View 8 Replies
View Related
Sep 21, 2011
How to find file by content on linux by command. Example: i want find file contain word "helo" on my computer (OS: LINUX)
View 4 Replies
View Related
Jun 13, 2010
How would i write a script which will add a following content to a file.File Before running script.
Code:
acpi = 1
apic = 1
builder = 'hvm'[code]....
View 3 Replies
View Related
Jan 13, 2010
I have a file called foo with a date string in it - and nothing else in the file
2010.01.13-22:28:28
I want to send this file content to date -s command so I can modify using a cron job.
I tried several ways to pipe the file contents to date command but did not work.
View 4 Replies
View Related
Oct 5, 2010
I am using find to search for .tgz files modified more than 7 days ago and delete them.find /directory/ -iname backup*.tgz -daystart -mtime +7 -exec rm -rf {} My problem is that find will go through the content of tarball as well and list all content. I want to only search main tarball and delete it if older than 7 days.
View 4 Replies
View Related
Nov 15, 2010
I've been having issues with my ubuntu server (10.04 LTS) lately. Every once in a while, anywhere from 3 days to a month or more, the server will just disappear from the network. All manner of trying to reach it from the outside fails, even from the LAN. Since it's headless, this is kind of problematic. After a hard power down or reboot, the server will always come back online, but this is very annoying for a remotely administered server.
What should I look for when trying to determine why the server keeps going offline? I can't tell if there are any other issues like a hard lockup or anything, just that it is not on the network anymore when this happens.
View 9 Replies
View Related
Jan 30, 2011
When I log onto my 10.04 server via ssh, there is the /etc/motd displayed. This motd is made up each time by the files in /etc/update/motd.d/. There is this one file : update-motd-reboot-required The content is exec /usr/lib/update-notifier/update-mot-reboot-required and the content of this one is : if the file /var/run/reboot-required exists, print it.
But who is making this file and why ?we know who it is: it's pam_motd.. but why would I reboot ??!?
editt2 : nvmd [URL]
View 1 Replies
View Related
Dec 18, 2010
I would like to lock the /etc/hosts file somehow in a way that only someone else can unlock it, possibly using a lock code.I would then give the passcode to someone else.I'm running Ubuntu 10.10.
View 2 Replies
View Related
Jul 19, 2011
I've trying to get dnsmasq working as a combined dns and dhcp server. It's infuriating so far... In short, the DNS works fine for anything added to /etc/hosts, and the dhcp works fine, but the dhcp is not updating the dns with hostname information from clients.
The outcome of this is that i can only ping a node by hostname if i know it's address, which means setting a static dhcp allocation and putting the hostname into /etc/hosts manually, which is very annoying and kind of defeats the poit of dhcp. There must be a way to get dnsmasq to update the hosts file, surely The clients aren't using fqdn's if that matters, and i think i've tried every combinination of "expand-hosts" and "domain=" following is the dnsmasq config file contents:
domain-needed
bogus-priv
except-interface=tun0
[code]....
View 2 Replies
View Related
Dec 18, 2010
I have a file clipboard.txt
I do :
Code:
sleep 10s ; echo "focus on the gedit" ; xclip -o clipboard.txt
is not working.
How to make that possible, how?
View 2 Replies
View Related
May 30, 2010
I have the following command that I run on cygwin:
find /cygdrive/d/tmp/* -maxdepth 0 -mtime -150 -type d | xargs du --max-depth=0 > foldersizesreport.csv
I intended to do the following with this command: for each folder under /d/tmp/ that was modified in last 150 days, check its total size including files within it and report it to file foldersizesreport.csv however that is now not good enough for me, as it turns out inside each
/d/tmp/subfolder1/somefile.properties
/d/tmp/subfolder2/somefile.properties
/d/tmp/subfolder3/somefile.properties
/d/tmp/subfolder4/somefile.properties
so as you see inside each subfolderX there is a file named somefile.properties inside it there is a property SOMEPROPKEY=3808612800100 (among other properties) this is the time in millisecond, i need to change the command so that instead of -mtime -150 it will include in the whole calculation only subfolderX that has a file inside them somefile.properties where the SOMEPROPKEY=3808612800100 is the time in millisecond in future, if the value SOMEPROPKEY=23948948 is in past then dont at all include the folderin the foldersizesreport.csv because its not relevant to me.so the result report should be looking like:
/d/tmp/,subfolder1,<itssizein KB>
/d/tmp/,subfolder2,<itssizein KB>
and if subfolder3 had a SOMEPROPKEY=34243234 (time in ms in past) then it would not be in that csv file.so basically I'm looking for:
find /cygdrive/d/tmp/* -maxdepth 0 -mtime -150 -type d | <only subfolders that have in them property in file SOMEPROPKEY=28374874827 - time in ms in future and not in past | xargs du --max-depth=0 > foldersizesreport.csv
View 1 Replies
View Related
Jul 16, 2011
I am calling a URL from shell script and passing few argumants,Here i have to pass file content as one argument.How can i pass file content through URL.
eg:
content=`cat /Users/test1.txt`
open http://localhost:8080?filecontent=$content
[code],...
View 1 Replies
View Related
Nov 9, 2010
I'm a Linux noob an I am really desperate for some top, top, top assistance. Been battling a while now with my iBurst USB modem driver and hope there is someone out there that can help? I have been through umpteen forums and threads and tried literally everything I read, but to no avail. I also realize there aren't many Ubuntu users that use the iBurst modem, but I am appealing to the few out there that do.
I have installed the open source ibriver-2.6.31 for my iBurst USB modem. Initially all went well with fast connection etc., connection everytime I boot, until... I started updates of 10.04 LTS, that is when I became aware, from the forums, that a re-install of the driver is required after every package update due to no "package management" in the iBdriver. what a pain in the proverbial to say the least!
Anyways.. now I am the stage where the driver is always installed, but...all of a sudden, I need to run pppoeconf and set up the driver after each boot to get connected!!!! If I can't find a solution it will force me back to Windoze7 which I dread to do! Can a script be written to pppoeconf (rp-pppoeconf.iso is loaded I think) automatically during boot perhaps?
So any top Linux hacker or "notsonoobasIam" user out there with a iBurst modem and similar pains & mis-fortunate experience please share your ideas and thoughts to correct this problem permanently for me please? (I should maybe mention that the other day I performed the "Grub2 Profile" exercise to try and speed up the boot time, this does not perhaps have something to do with the fact that I need to reconfigure in pppoeconf after every boot does it? I doubt it)
View 9 Replies
View Related
Jun 27, 2011
Working fine: ==> scp my_log-bin.01393[0-9] root@192.168.103.66:/backup/ error - No such file or directory: ==> scp my_log-bin.0139[30-99] root@192.168.103.66:/backup/
View 4 Replies
View Related
Mar 10, 2011
I was doing a tutorial on scripting in bash. I saved my file on the desktop and I cannot seem to get to that file to execute it. Here is what I have been using:
I try cd Desktop says that there is no such directory.
I tried /home/me/Desktop same thing.
View 5 Replies
View Related