自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

编程岁月

软件开发技术心得+笔记

  • 博客(14)
  • 问答 (1)
  • 收藏
  • 关注

转载 How do I grab an INI value within a shell script?

I have a parameters.ini file, such as:[parameters.ini]    database_user    = user    database_version = 20110611142248I want to read in and use the database version specified in the parameters

2014-05-10 14:32:49 575

转载 How to start weblogic managed servers without manually entering the password

While starting a managed server in weblogic, we start with below command.  1 /bin/startManagedWebLogic.sh soa_server1 t3://localhost:7001 This command will prompt to manually enter the use

2014-05-10 14:30:33 837

转载 -bash: ./my_script: /bin/bash^M: bad interpreter: No such file or directory

26down voteaccepted  I have seen this issue when creating scripts in Windows env and then porting over to run on a unix environment.Try running this on the script:http://linuxcommand.org/man_p

2014-05-10 14:27:46 847

转载 bash split string into array

In a bash script I would like to split a line into pieces and put them into an array.The line:Paris, France, EuropeI would like to have them in an array like this:array[0] = Parisarray[1] =

2014-05-10 14:25:52 1687

转载 How to check the first character in a string in unix

Many ways to do this. You could use wildcards in double brackets:str="/some/directory/file"if [[ $str == /* ]]; then echo 1; else echo 0; fiYou can use substring expansion:if [[ ${str:0:1}

2014-05-10 14:22:50 806

转载 Linux Bash script to remove files older than 3 days

Can someone help me with a bash script to remove files older than 3 days in directory /u1/database/prod/arch?

2014-05-10 14:10:40 765

转载 Oracle Weblogic nodemanager STOP script Bash and Python

Everyone who is using Oracle Weblogic must had a thought like  “Where the *** is the stop script to kill my nodemanager proces”…. Well, i did. So i wrote a simple stop script which can be better proba

2014-05-10 14:07:44 871

转载 Linux Grep OR, Grep AND, Grep NOT Operator Examples

Question: Can you explain how to use OR, AND and NOT operators in Unix grep command with some examples? Answer: In grep, we have options equivalent to OR and NOT operators. There is no grep AND op

2014-05-10 14:05:59 896

转载 Start and Stop Oracle Weblogic NodeManager Via Shell Alias

Start and Stop Oracle Weblogic NodeManager via Shell Alias This tip is to create two simple bash shell environment alias for starting and stoping Weblogic Node Manager. No script is needed.  A

2014-05-10 14:03:26 706

转载 How do I determine if a web page exists with shell scripting?

Under a *NIX, you can use curl to issue a simple HEAD request (HEAD only asks for the headers, not the page body):curl --head http://myurl/Then you can take only the first line, which contains t

2014-05-10 14:01:39 595

转载 Listing only directory using ls in bash

This command lists directory in the current path: ls -d */What exactly the pattern */ does?And how can we give absolute path in the above command (like ls -d /home/alice/Documents) for listing onl

2014-05-10 13:58:32 776

转载 【转】linux shell -- 块注释

使用#可以注掉一行脚本,但shell没有提供类似c语言/* */的成块注释符。所以shell中的块注释只能通过一些技巧实现。1. 使用here document:语句块block这里的block是标识符,可以自定义。注意不要与语句块中的字符产生冲突。解释:最前面的:表示空命令,是bash的内建命令。一个here document就是一段带有特殊目的的代码段。它使用I

2014-05-06 18:47:34 1856

转载 在Linux中用source,dot(.)和直接用脚本文件名执行shell脚本的区别 .

用source,dot(.)的方式执行shell脚本的时候,不产生子进程,shell脚本在当前的shell中运行,shell脚本运行完成后,在shell脚本中声明的变量在当前的shell中是可见的.直接用脚本文件名的方式执行shell脚本的时候,产生子进程,shell脚本在子进程中运行,shell脚本运行完成后,在shell脚本中声明的变量在当前的shell中是不可见的.验证过程:

2014-05-06 18:45:19 1057

转载 [转]linux shell 获取当前正在执行脚本的绝对路径

原文链接:http://sexywp.com/bash-how-to-get-the-basepath-of-current-running-script.htm 常见的一种误区,是使用 pwd 命令,该命令的作用是“print name of current/working directory”,这才是此命令的真实含义,当前的工作目录,这里没有任何意思说明,这个目录就是脚本存放的目录。所

2014-05-06 18:41:16 754

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除