![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Change directory in a shell script | laxmi | Linux | 12 | 01-17-2008 08:07 AM |
| change directory using shell script | laxmi | Shell Programming and Scripting | 0 | 01-17-2008 07:12 AM |
| Change Password In A Shell Script | pintu_asim | Shell Programming and Scripting | 6 | 06-29-2006 11:16 AM |
| change user through shell script | raviraushanjha | UNIX for Dummies Questions & Answers | 0 | 12-12-2005 03:11 AM |
| script to change shell and prompt | SHYAM | Shell Programming and Scripting | 1 | 06-27-2004 09:46 AM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
Shell script to change a value
I have a shell script that has following entry.
MEM_ARGS="-Xms256m -Xmx512m" export MEM_ARGS if [ "${JAVA_VENDOR}" = "Sun" ] ; then if [ "${PRODUCTION_MODE}" = "" ] ; then MEM_DEV_ARGS="-XX:CompileThreshold=8000 -XX:PermSize=48m " export MEM_DEV_ARGS fi fi # Had to have a separate test here BECAUSE of immediate variable expansion on windows if [ "${JAVA_VENDOR}" = "Sun" ] ; then MEM_ARGS="${MEM_ARGS} ${MEM_DEV_ARGS} -XX:MaxPermSize=512m" export MEM_ARGS fi if [ "${JAVA_VENDOR}" = "HP" ] ; then MEM_ARGS="${MEM_ARGS} -XX:MaxPermSize=128m" export MEM_ARGS fi I want to change the line MEM_ARGS="-Xms256m -Xmx512m" to new value lets say MEM_ARGS="-Xms512m -Xmx1024m" . The intention is tha twhetever the value to be given it should go and set Xms and Xmx values.The problem here is that I can't find for word MEM_ARGS= and replace then becuase MEM_ARGS= is existing multiple places. So probably I need to search for "MEM_ARGS="-Xms" in this file and then replace the value that I want. Can you please suggest the best possible commands? Thanks in advance, Rijesh. |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|