WshShell objects
ProgID Wscript.Shell
FileName Wshom.ocx
CLSID f935dc22-1cf0-11d0-adb9-00c04fd58a0b
IID f935dc21-1cf0-11d0-adb9-00c04fd58a0b
The following table describes the properties associated with the WshShell object.
Attribute
Sometimes I want to find an IP in my home to test the virtual machine. But do not remember those IP is in use, those who do not use (don't say you remember, OK, I admit I am old), so wrote a shell script to detect, easy to use. Script content:
#
$: Gets the file name of the currently executing script, including the path.
[Root@test script]# Cat 0.sh#!/bin/bashecho $[Root@test script]# SH 0.sh0.sh[Root@test script]# Cat 0.sh#!/bin/bashDirName "$"BaseName "$"[Root@test script]#
Single modification:
The code is as follows
Copy Code
echo test:23456 | chpasswd
Batch modification:
First in a text file (assuming the name Users.txt) to prepare account information, the format is "account:
In the afternoon, when writing a program, you need to assign the value returned by the shell command to a variable, using the a=$ () method
soft=$ (grep-i "\ Software \) token/passcode/." 123.txt |wc-l)
echo "[+] Soft card total:" $soft
......
The
Objective
Many commands are executed simultaneously during Linux operations or during day-to-day Linux operation, so that it needs to be handled through our multiple command methods. Multi-order execution includes '; ' And the ' && ' command so
In view of debugging Logback and log4j file cutting has been unsuccessful, with the use of shell script to cut the log files under Tomcat (if you have in the Logback or log4j use file cutting success, you can leave the use of the way, first thank
I. Management of the Document System
Tips: When you enter a command, you need to use the TAB key to complete
LS View directory information (LS/)
Ls-l equivalent to LL
PWD View the path that is currently in place
CD switch directory (CD/) and
Part 1: ' Command '
This is the "command standard output as a function of standard input" method of operation, there are great drawbacks and unsafe places.
disadvantage one: relatively old.
disadvantage two: easy to confuse with single quotes.
What is an app shell (app shell)The app shell is the most basic HTML, CSS, and JavaScript required for the application's user interface, and a component to ensure that the application has a lot of performance. Its first load will be very fast and is
Dim myProcess As New Process () 'first defines a Process variablePrivate Sub button#click (ByVal sender As System. Object, ByVal e As System. EventArgs) Handles Button1.ClickMyProcess. StartInfo. FileName = "Notepad"MyProcess. StartInfo. WindowStyle
There is a very important command in Linux that can help us record the commands we have used. It is useful for troubleshooting or intrusion detection in the future. This article organizes the configuration into a script and runs the script directly
Note: Operating system: CentOS Web server: apache Problem: Search engine crawlers increase website access volume in a certain period of time. The server is under heavy pressure, the website access times out, and the page cannot be
Nginx does not support using cronolog to rotate logs like Apache, but you can use the following methods to cut log files:Mv/data1/logs/access. log/data1/logs/20111030.logKill-USR1 Nginx master process numberUse the mv command to rename the log file
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.