Cannot Modify Bash Profile

Mar 1, 2008

Code:
-rw-r--r-- 1 root root 975 Dec 22 2006 .bash_profile
root@server [~]# rm -f .bash_profile
rm: cannot remove `.bash_profile': Operation not permitted

root@server [~]# chmod +t .bash_profile
chmod: changing permissions of `.bash_profile': Operation not permitted

I simply wanted to modify something within the file but I keep getting permission errors. I'm logged in as root.

View 3 Replies


ADVERTISEMENT

Error From /etc/profile

Feb 6, 2007

I modified /etc/profile on CentOS 4.3, after failed, I change everything back. but I got errors as follows:

: command not found
: command not found
'ash: /etc/profile: line 6: syntax error near unexpected token `{
'ash: /etc/profile: line 6: `pathmunge () {

I am pretty much sure the file is as same as original one. but no idea on why the error occurs?

My full content of profile is:

Code:
# /etc/profile

# System wide environment and startup programs, for login setup
# Functions and aliases go in /etc/bashrc

pathmunge () {
if ! echo $PATH | /bin/egrep -q "(^|:)$1($|:)" ; then
if [ "$2" = "after" ] ; then
PATH=$PATH:$1
else
PATH=$1:$PATH
fi
fi
}

# Path manipulation
if [ `id -u` = 0 ]; then
pathmunge /sbin
pathmunge /usr/sbin
pathmunge /usr/local/sbin
fi

pathmunge /usr/X11R6/bin after

# No core files by default
ulimit -S -c 0 > /dev/null 2>&1

USER="`id -un`"
LOGNAME=$USER
MAIL="/var/spool/mail/$USER"

HOSTNAME=`/bin/hostname`
HISTSIZE=1000

if [ -z "$INPUTRC" -a ! -f "$HOME/.inputrc" ]; then
INPUTRC=/etc/inputrc
fi

export PATH USER LOGNAME MAIL HOSTNAME HISTSIZE INPUTRC

for i in /etc/profile.d/*.sh ; do
if [ -r "$i" ]; then
. $i
fi
done

unset i
unset pathmunge

View 2 Replies View Related

High-Profile Blog

Oct 9, 2009

I'm going to be setting up and hosting a high-profile wordpress blog. It'll probably get around 800.000 pagehits per month. The client has been asking about Peak Capacity, Throughput and whatnot and I'm honestly am not sure what to tell him.

So far I've been maintaining a 1and1 windows 2003 dedicated server with about 20 websites, but none which comes close to that amount of traffic.

My plan is to go for a Linux box with the following specs:

CPU: Opteron 1218 HE

CPU Details: 2 x 2.6 GHz

RAM:4 GB RAM

Hard Disks: 2 x 400 GB (RAID 1 Software)

Bandwidth: 100Mbps

View 9 Replies View Related

Apache :: Myspace Style Profile Name Mod Rewrites?

Jun 22, 2011

How do you do Myspace Style Profile Name Mod Rewrites?

I have Mod-rewrite code turned on for Friendly URLS in options.

But for member profiles in .htaccess. I want it to look like this:

[URL]...

Instead of this:[URL]...

This way members can link friends to their profile easier. 

View 3 Replies View Related

Apache :: AH00370 Failed To Create WinNT Service Profile

Feb 15, 2014

I've got the following Issue with Apache 2.4.7: <OS 5> Zugriff verweigert: AH00370: Failed to create WinNT Service Profile

Well i should mention, that the same Packages are running properly configured in a Virutal Machine (same configuration as my Livemachine) without any problems whatsoever.

Its my Livemachine, where Apache keeps returning this Message while attempting to install Apache as a Service.

Installed Packages:

Apache: httpd-2.4.7-win32-VC11.zip
PHP: php-5.5.7-Win32-VC11-x86.zip
MySQL: mysql-installer-community-5.6.15.0
phpMyAdmin-4.1.3-all-languages.zip

OperatingSystem: Windows 7-64 Ultimate SP1

UAC: Disabled
CMD: tried the "Execute as Administrator" as well as without (<- which is always working in my Case)

Logfile: Apart from the ususal "install.log", nothing else inside the Logs Folder.

Even reinstalled Apache twice, with- and without my Configurationfiles, but still got the same results.

View 2 Replies View Related

Modify /tmp Size

Jul 11, 2008

Used chirpy's method

/etc/init.d/chkservd stop
/etc/init.d/mysql stop
umount /var/tmp
umount /tmp
replace "256000" "512000" -- /scripts/securetmp
rm /usr/tmpDSK
/scripts/securetmp --auto
cd /tmp
ln -s /var/lib/mysql/mysql.sock
/etc/init.d/mysql start
/etc/init.d/chkservd start
df

Problem

[root@host ~]# umount /tmp
umount: /tmp: device is busy
umount: /tmp: device is busy
[root@cmee34 ~]# lsof | grep /tmp
sshd 6650 root 9u unix 0xf57fe300 24988 /tmp/ssh-SDVLUi6650/agent.6650

If I killall -9 sshd, I got obviously logged out of ssh. I need to make /tmp 1GB instead of the current 500MB it is now.

View 2 Replies View Related

Modify MaxClients

Jun 13, 2008

i want to larger the "MaxClients",

i add the MaxClients 1000 in the httpd/conf/httpd.conf and restart the httpd

but it looks likely not work at all,

what should i do else?

my apache is version 2

View 10 Replies View Related

Modify Domain Name On Plesk

Jun 10, 2009

i need to modify a domain name in plesk. is that possible without having to recreate the account or losing the info?

for example from [url]to [url]

View 2 Replies View Related

How To Allow Customers To Modify Their Own Php.ini Settings

May 29, 2007

On the server (linux, cpanel), we have global registers set to off. Some scripts require them on. What's the most secure way to allow customers to do their own settings for their own domains and bypass the main server php.ini settings?

View 4 Replies View Related

How To Modify SPF Record For An IP That Is Shared?

May 30, 2007

fix some DNS errors for the shared IP on the server. Noramlly inside cPanel, we would edit zone file for each domain. How do we make DNS changes for the IP address used as the shared IP on the server?

View 7 Replies View Related

# Of Apache Requests - Modify

Feb 8, 2007

I have a dedicated box with softlayer and I have noticed at varying times the past few months that with sites we host, sometimes the connection times out (I'll try to access like 5 or 6 sites within 30 seconds or so and they all drop, then a minute later they load fine).

I opened a support ticket and they said it usually has to do with the # of requests Apache can handle, and that this can be modified. They stated they could: "tweak the apache configuration file in this server that can make it possible to handle more requests."

So my question is what should the # of requests be set to? (I'm not sure what it is now, but I assume whatever the default # is).

View 6 Replies View Related

CPanel: Modify Or Create An Account

Apr 6, 2007

I've just run upon a problem while trying to go into my phpMyadmin from within my MySQL Databases icon.

When I try to log into phpMyadmin I get this message:

Quote:

"This feature is not available while logged in with root override. You are logged in with the root, or reseller's password. Please login with this user's account password."

Also, as soon as I log into cPanel I receive a red "Warning: You are logged in using the reseller or root password." Yes, I am logging into the only account I have.

When logging in with the initial account I created I can view the MySQL dbs that I have created, but I don't have access to phpMyadmin - I get that error message. This is new because for the last two weeks - about as long as I've had this server - I have had no problem even signing in with the same user id and password. Suddenly it won't let me in.

So what do I need to do?

I created a new account, but I can't see my MySQL dbs with that new account.

I don't know how to modify my one existing account so that I can access phpMyadmin.

Any thoughts? I hope I've been clear.

View 8 Replies View Related

Apache :: Give Someone Access To Modify Settings Through WHM?

Nov 13, 2013

I have WHM and Cpanel on my dedicated server. Is there a way to give them access to change this? I dont want then to have access to everything either.

Edit your httpd.conf file.

Timeout 50
KeepAlive On
MaxKeepAliveRequests 120
KeepAliveTimeout 10
MinSpareServers 10
MaxSpareServers 20
StartServers 16
MaxClients 125
MaxRequestsPerChild 5000 

View 4 Replies View Related

You Have A Mail Bash:~#

Jun 15, 2008

I opened up my VPS bash today and I saw a message like this:

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
..........................
..........................
You have a mail.
bash:~#

Now I am confused from where have I received a mail, and even if I have received it why doesn't it shows in Google Apps??

I have set the MX Entries correctly and when I sent a mail specifically to admin@mysite.com , I do get a mail in google apps.

Anyways where does this mail lie, how can I view this mail ?? I installed postfix as my mailing server.

View 6 Replies View Related

SSH Bash Error

Aug 9, 2008

When I log into my clients VPS via SSH and I get the following error...

login as: root
root@69.162.67.44's password:
Last login: Sun Jan 20 23:33:36 2008 from 122.167.25.31
-bash-3.1#

View 11 Replies View Related

Bash SSH Command

Jun 30, 2007

I've just about got my mysqldump script ready,

Here is what it looks like:

Code:
#!/bin/sh
mysqldump -uusr -ppwd --opt db > /home/usr/dbs/1.sql
mysqldump -uusr -ppwd --opt db2 > /home/usr/dbs/2.sql

cd /home/usr/dbs
tar -zcvf sqldata.tgz *.sql

How would I make my finished gzipped file's filename to include the date?

Would I add any tags infront of sqldata.tgz *.sql?

Or would I have to run another command after the last line?

View 14 Replies View Related

Bash Script

Jun 1, 2007

I could use a bash script for a crontab that does a regular backup of my mysql database.

Unfortunately i can't employ one of the made-up backup scripts using mysqldump because i need to use mysqlhotcopy (that's because i need the raw data for a charset mess in mysql with some foreign languages not classifieds as utf8 .. long story), and i'm a total ignorant of perl and bash scripting.

The script (that will be recalled via cron) has to:remove all the .tar.gz files older than X days in the folder /xxx/backup, if the folder contains more than X tar.gz files
create a folder /xxx/backup/$todaydate call the command "mysqlhotcopy --bla -bla -bla " that will copy the dbase in the previously created /xxx/backup/$todaydate folder
at the end of the previous operation (if successful) compress the $todaydate folder in a $todaydate-sqlbackup.tar.gz file at the end of the previous operation (if successful) delete the uncompressed folder. launch the "rsync -bla -bla" command to syncronize this folder with a remote server I thought it will be something like a 10lines script, and i'll be glad to hand you a couple of virtual beers (via paypal ) as a thank you sign, but if the script is not trivial and you're willing to help anyhow, of course i'm willing to pay more.

View 1 Replies View Related

Apache As Bash

Dec 6, 2007

apache 11421 0.0 0.3 2704 1712 ? Ss Oct09 4:35 bash
apache 11625 0.0 0.1 1912 884 ? Ss Oct09 1:12 bash
apache 14454 0.0 0.0 1764 128 ? Ss Oct17 0:00 /usr/sbin/apache
apache 15216 0.0 0.2 2308 1356 ? Ss Nov10 1:58 bash
apache 19597 0.0 0.2 2308 1336 ? Ss Nov10 1:50 bash
apache 22164 0.0 0.3 2704 1772 ? Ss Oct11 1:11 bash

I stopped apache but can see these when i do ps aux.

View 2 Replies View Related

Plesk 12.x / Linux :: Where To Modify Nginx Fastcgi Settings

Dec 8, 2014

What exact file to modify in order to optimize fastcgi settings, then to set default for all websites. Sample code below:

# execute all .php files via php-fpm
location ~ .php$ {
# connect to a unix domain-socket:
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;

[Code] ....

View 4 Replies View Related

Plesk 12.x / Linux :: Modify Firewall Rules Never Completes

Nov 9, 2014

Applying Plesk firewall changes? I make my change, apply and get to:

Status: Applying in progress. If your browser shows connection error messages, or if this screen does not disappear in more than 30 seconds, go to previous page.

And there things stay. Going back to look at the firewall I can see the change haven't been applied, and going to apply just results in the same. No error, just no anything. It also took numerous attempts to get firewall modification to be swtich on although finally at about the eighth attempt changes were enabled. Only now I can't apply them ...

View 5 Replies View Related

Plesk 12.x / Linux :: Modify Permissions On User Www-data

May 6, 2015

We cant' modify any files of my website in WordPress that contain user www-data.

How can you can change the permissions to this user (www-data).

The version is Plesk 12.0.18 Actualización #44

We have also Plesk 11.5 with WordPress and never has www-data user.

View 3 Replies View Related

Litespeed And Bash Script

Jun 4, 2009

I'm having a problem with litespeed and apache, every time when I reboot the server listespeed and apache(both) are started and the server uses apache. I configured litespeed to use a conf file of apache so I can't remove just apache. I need a way when I restart the server litespeed is started and apache is stoped

2nd problem. how to make this in a batch script
The script will backup a directory every month and I need in every backup get a date like this directoryname-date(day/month/year)

View 4 Replies View Related

Linux BASH Scripting

Dec 7, 2008

I am currently trying to create a bash script which I will run off a loop with a sleep interval that will query tcpdump (udp packets only) on a network interface, and is looking for length 10 packets.

So far so good, not that hard to code I know (Already made it / coded it this far perfectly). Now here is the tricky part, I only want the bash script to identify IP's that have sent over 15 packets with the length of 10. (This is the part that I can't seem to find a way to code).

I was thinking, from the output maybe to calculate the number of lines with the same equal IP's.

Once this script identifies that, it will automatically run a command which I have set. (Quite easy, and I can do this).

I am looking for someone to help me with this. It is a fairly simple and quick job (editing the script I have at the moment). I am willing to also pay (if needed) an amount for this to be completed too. Obvieusly not that much, but still something I am sure we can work out.

View 2 Replies View Related

Simple Bash Script

Sep 24, 2007

somebody to write a very simple bash script to me , which will help me to "wget" some text files!

i want to do the following:
wget [url]

X changes for evey folder (main group)
Y will change for every file in the folder.

eg:
[url]
[url]
[url]


the next group:

[url]
[url]
[url]

The X value range [1-100]
the Y value range [1-13]

View 3 Replies View Related

Removing File -bash: /bin/rm

Mar 31, 2007

Sometimes if I tried to use rm to remove too many files I got this:

-bash: /bin/rm: Argument list too long

I think there was a workaround, like ls and then piping the result to rm, but I forget.

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved