Linux removes all generated log files from Tomcat

#!/bin/bash#!/bin/bash#exact All log files#计算log文件个数log_number= ' ls *.log |grep log-c '#当log文件数大于0时遍历删除文件中的文件夹If [$log _number-gt 0];thenlist_log_files=$ (LS *.log)#Traverse to delete filesFor log_file in $list _log_filesDo#delete All log

Linux Basic Learning -9.5-soft and hard links

One, soft connection1, how to comeLn-s Creating a soft connection[Email protected] oldboy]# ln-s oldboy.txt oldboy.txt-soft[Email protected] oldboy]# ls-l oldboy.txt*-rw-r--r--. 1 root root 05:10 oldboy.txtlrwxrwxrwx 1 root root 12:09

Network operation after initial installation of Linux

System environment:[Email protected] ~]# cat/etc/redhat-releaseCentOS Linux release 7.2.1511 (Core) [Email protected] ~]# rpm-q centos-releaseCentos-release-7-2.1511.el7.centos.2.10.x86_64Kernel version:[Email protected] ~]# cat/proc/versionLinux

Linux Interesting commands screen

Screen similar to a container, you can put the current foreground running Application Shell window closed without affecting the operation, and after the nohup a bit similar, but I think it is more useful than nohupUsage 1:ScreenThen it pops up a new

Linux Basic Learning -6.5-How to modify host names

1. Host name configuration file[Email protected] ~]# cat/etc/sysconfig/networkNetworking=yesHostname=brj2. View Host Name[Email protected] ~]# hostnameBrj3. Temporarily modify host name[Email protected] ~]# hostname oldboy364. Permanently modify the

Linux Common commands

1.xargs combined with find useWhen you delete too many files with RM, you may get an error message:/BIN/RM Argument list too long. Use Xargs to avoid this problem:Find. -type F-name "*.log"-print0 | xargs-0 rm-fThe xargs-0 is used as a

Linux Basic Learning -10.2-wildcard review

1. * EverythingEnd With. txt *.txtEnd With. Log *.logA file in the system that begins with LS.Find/-type f-name "ls*"Locate the file in the system that contains Oldboy.Find/-type f-name "*oldboy*"2. {} Generate Sequenceecho {1..10}echo {10..1}echo {0

Getting Started with Linux basics

Linux Time Line System V and BSD in the 80 's copyright dispute 1990 BSD transplant to X86 386 plan aborted 1991 Finnish Linus invented Linux 1994 Linux1.0 released for use in production environments Operating systemOS =

Linux View all user and group information

Mainly through the following two commands:cat/etc/passwdCat/etc/groupStep One: CAT/ETC/PASSWD View all user information, details such as:Step 2:cat/etc/passwd|grep user name to find a user, details see:Step three: Cat/etc/group View all group

First time contact with Linux

The first contact with Linux is a very simple small project to restart the project, but because it has not been contacted before, I recorded a simple operation.Before using the Linux server to download the installation Xshell and Xftp, after the

2018-06-05 Linux Learning

20.23 Alarm system Mail engine (UP)mail.sh Contentwhich mail.py content to download here https://coding.net/u/aminglinux/p/aminglinux-book/git/blob/master/D22Z/mail.pyLog=$1t_s=date +%sT_s2=date -d "2 hours ago" +%sif [!-f/tmp/$log]Thenecho $t _s2 >/

Linux Common Commands--sudo

sudo 以另一个用户身份执行命令Syntax format: sudo "option" sudo [options]Note: There must be at least one space between each element in the sudo command and subsequent options and filesParameter options:-L, which lists the commands that the current user can

The security minimization principle of Linux system

The minimization principle is extremely important for Linux system security, that is, more than a few things, including the following aspects: Install the Linux system minimized, that is, the package is minimized, yum installation package

Preparing the Linux environment for Hadoop clusters

1. Modify the host name:Under root account, use the command: vi/etc/sysconfig/networkor sudo vi/etc/sysconfig/network2. Set the system default boot levelEnter the Vi/etc/inittab level in the root account to change to 3Each start-level representative

Linux Learning Summary (56) Monitoring Zabbix deployment Next

Zabbix Application ExamplesAdd a custom monitoring itemLet's take an example: monitor the number of concurrent connections on a Web server 80 port and set up a graph.1. Write a script that can crawl the data and create a script on the client

Linux Add Scheduled Tasks

Crond is a command that Linux uses to execute programs on a regular basis. This task Dispatch command is started by default when the operating system is installed. The Crond command periodically checks to see if there is any work to be done and the

centos7.4 Linux Instructions

1. View versionlsb_release -a2. View MySQL PathWhereis MySQL3. View the EncodingLocale4. Install FTPInstallationYum install-y vsftpd//InstallationSystemctl start Vsftpd.service//Start VSFTPD ServiceFTP Permissions configuration:The configuration

20180530 Morning Lesson Records-linux

1.tar Unzip what problemUser User groups2. What is the search for XXX command?Find/-name XXX3. We execute the order, actually go to which variable to findPATH4. Talk about the parameters of the big R commandChown chmod5. Talk about small R

Basic Linux Learning

Learning content: Intermediate: System Foundation, System management, network security and network services, shell scriptingAdvanced: MySQL database, clustering, distributed systems and virtualization technologies: XEN,KVM, operation and maintenance

Programmer's Document browsing tool under Windows/linux

Dash + Alfredhttps://www.jianshu.com/p/77d2bf8df81fFor programmers, viewing the API documentation is very frequent, and switching between the regular Windows is cumbersome, and there is a document-checking artifact on the Mac: Dash.Detailed use can

Total Pages: 5467 1 .... 5376 5377 5378 5379 5380 .... 5467 Go to: GO

Contact Us

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.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.