Linux
dijk
这个作者很懒,什么都没留下…
展开
-
Ubuntu: Command: 设置root密码
Ubuntu设置root密码终端输入sudo passwd root,在[sudo] password for landry:后输入当前用户的密码当前用户密码验证通过后输入需要设置的root超级管理员账户密码Enter new UNIX password:验证输入的密码Retype new UNIX password:出现passwd: password updated succe...原创 2019-02-19 09:08:53 · 298 阅读 · 0 评论 -
Problem: xxx is not in the sudoers file. This incident will be reported
ProblemThere is a problem when user dijk execute command below:$ sudo usermod -aG vboxsf dijkor$ sudo gpasswd -a dijk vboxsfProblem: “dijk is not in the sudoers file. This incident will be rep...原创 2018-11-15 23:44:36 · 277 阅读 · 0 评论 -
Problem: MySQL: -bash: mysql: command not found
ProblemProblem: MySQL: -bash: mysql: command not foundOn CentOS, MySQL works fine, but can not use “mysql” command in terminal, and says “-bash: mysql: command not found”.Solution# cd /usr/local/...原创 2018-11-15 22:54:51 · 179 阅读 · 0 评论 -
Problem: WARN bitronix.tm.Configuration - cannot get this JVM unique ID. Make sure it is configured
Problem[main] WARN bitronix.tm.Configuration - cannot get this JVM unique ID. Make sure it is configured and you only use ASCII characters. Will use IP address instead (unsafe for production usage!)...原创 2018-11-15 22:22:18 · 732 阅读 · 0 评论 -
CentOS: Command: 删除多余内核
CentOS 删除多余内核# 查看当前系统中的kernel# rpm -qa | grep kernel# 删除不需要的kernel[kernel devel...]# yum remove kernel-...# 安装需要的内核# yum install kernel-......原创 2018-11-15 22:00:23 · 202 阅读 · 0 评论 -
Problem: Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took...
ProblemWARNING [main] org.apache.catalina.util.SessionIdGeneratorBase.createSecureRandom Creation of SecureRandom instance for session ID generation using [SHA1PRNG] took [1,139,942] milliseconds.So...原创 2018-11-15 21:54:35 · 1232 阅读 · 0 评论 -
MySQL: 数据库拒绝访问[远程连接]
MySQL: 数据库拒绝访问[远程连接]登录MySQL$ /usr/local/mysql/bin/mysql -u root -pmysql> user mysql;mysql> select host from user;mysql> update user set host ='%' where user ='root';mysql> exit;重...原创 2018-11-11 18:31:46 · 994 阅读 · 0 评论 -
Command: 查看log日志
查看log日志命令cat catalina.outortail -5000f catalina.out原创 2018-11-11 18:19:08 · 744 阅读 · 0 评论 -
MySQL: 设置表名不区分大小写
MySQL: 设置表名不区分大小写vi修改/etc/my.cnf# vi /etc/my.cnf 在[mysqld]段后附加一句:lower_case_table_names=1如:[mysqld] datadir=/var/lib/mysql socket=/var/lib/mysql/mysql.sock lower_case_table_names=1重启MySQL...原创 2018-11-11 18:16:01 · 194 阅读 · 0 评论 -
MySQL: 忘记root密码: skip-grant-tables
MySQL 忘记root密码修改MySQL的登录设置# vi /etc/my.cnf 在[mysqld]段后附加一句:skip-grant-tables如:[mysqld] datadir=/var/lib/mysql socket=/var/lib/mysql/mysql.sock skip-grant-tables 重启MySQL登录并修改MySQL的root密码# ...原创 2018-11-11 18:07:17 · 227 阅读 · 0 评论 -
MySQL: CentOS6.8: ERROR 1044 (42000)
MySQL: ERROR 1044 (42000)现象mysql> use mysql;ERROR 1044 (42000): Access denied for user ''@'localhost' to database 'mysql'如果使用“mysql -uroot -p”登陆会报错,即使密码正确也不能登录,而且发现,直接用“mysql -uroot”不输入密码也可以登...原创 2018-11-11 17:58:41 · 337 阅读 · 0 评论 -
Command: SecureCRT: 压缩打包、下载、上传命令
SecureCRT 压缩打包、下载、上传命令压缩打包tar -czvf 压缩后文件名.tar.gz(含路径) 要压缩的文件名(含路径)如 tar -czvf xxx.tar.gz xxx/ xxx1 xxx2 xxx3 多个待打包文件以空格分隔下载sz 压缩后文件名.tar.gz(含路径)上传rz 直接回车 -> 出现选择文件的弹窗...原创 2018-11-11 17:23:34 · 1099 阅读 · 0 评论 -
Command: 查看linux系统版本信息
查看linux系统版本信息(Oracle Linux、Centos Linux、Redhat Linux、Debian、Ubuntu)查看Linux系统版本的命令(3种方法)1、cat /etc/issue,此命令也适用于所有的Linux发行版[root@S-CentOS home]# cat /etc/issueCentOS release 6.5 (Final)Kernel \r o...原创 2018-11-11 17:08:37 · 632 阅读 · 0 评论 -
Command: 端口进程相关
端口进程相关Win10端口netstat -aon | findstr "端口号"进程根据进程号查看进程信息tasklist|findstr "15560"taskkill /pid 15560 /f成功: 已终止 PID 为 15560 的进程。Linux端口netstat -anl | grep "端口号"netstat -anp | grep 8282lso...原创 2018-11-11 16:58:47 · 262 阅读 · 0 评论 -
VirtualBox: CentOS7.5 install VBoxLinuxAdditions
VirtualBox: CentOS7.5 install VBoxLinuxAdditions# yum install gcc# yum install gcc-c++// 版本要根据具体情况# yum install kernel-devel-3.10.0-862.el7.x86_64# reboot// 在桌面上打开增强功能包光盘,将VBoxLinuxAdditions....原创 2018-11-21 08:08:31 · 261 阅读 · 0 评论 -
CentOS: install jdk1.8
CentOS: install jdk1.8DownloadDecompress# mkdir /usr/local/java/// Decompress to '/usr/local/java/' directory# tar -zxvf jdk-8u151-linux-x64.tar.gz -C /usr/local/java/Environment variable# ...原创 2018-11-21 08:33:05 · 230 阅读 · 0 评论 -
Alpine: install SDKMAN!
Alpine install SDKMAN!InstallInstalling SDKMAN! on UNIX-like platforms is as easy as ever. SDKMAN! installs smoothly on Mac OSX, Linux, Cygwin, Solaris and FreeBSD. We also support Bash and ZSH she...原创 2018-12-10 20:52:13 · 734 阅读 · 0 评论 -
CentOS: install git
CentOS install git// install gityum –y install git原创 2018-12-17 00:03:14 · 187 阅读 · 0 评论 -
Alpine: install docker
Alpine install dockerInstall docker// 安装docker,并使其服务端随系统启动# apk add docker# ln -s /etc/init.d/docker /etc/runlevels/default/dockerDocker mirror acceleration// Docker国内镜像加速# touch /etc/docker...原创 2018-12-10 20:39:41 · 516 阅读 · 0 评论 -
VirtualBox: Installing Alpine 3.8.1
VirtualBox Installing Alpine 3.8.1Install启动虚拟机,用光盘启动,然后用root登录AlpineLinux,没有密码敲入命令setup-alpine跟随命令行向导一步一步执行在选择安装源时,敲入“f”让系统自己寻找一个最快的源在选择安装目标盘时,敲入“sda”在选择分区类型时,敲入“sys”装完了,退出光盘,重启虚拟机Confi...原创 2018-12-10 20:28:42 · 437 阅读 · 0 评论 -
Linux: see file size command
Linux: see file size command// see file size# ls -lht原创 2018-12-16 15:14:44 · 359 阅读 · 0 评论 -
Alpine: install zsh and oh-my-zsh
Alpine: install zsh and oh-my-zsh# cat /etc/shells# valid login shells/bin/sh/bin/ash/bin/bash# apk add zsh# cat /etc/shells# valid login shells/bin/sh/bin/ash/bin/bash/bin/zsh// chang...原创 2018-12-16 14:53:44 · 1582 阅读 · 0 评论 -
Alpine: change current shell
Alpine change current shell// change current shell# vi /etc/passwd# change by dijkroot:x:0:0:root:/root:/bin/ash#root:x:0:0:root:/root:/bin/bash// see current shell# echo $0or# echo $SHELL...原创 2018-12-16 14:49:17 · 731 阅读 · 0 评论 -
Alpine: install docker compose
Alpine install docker compose// seems there is a problem with Alpine 3.8.1 virtual, can not work!# apk add curl# curl -L "https://github.com/docker/compose/releases/download/1.23.2/docker-compose-...原创 2018-12-16 14:44:40 · 453 阅读 · 0 评论 -
Problem: Docker: Is docker daemon running?
ProblemIs docker daemon running?Solution// start docker daemon# dockerd原创 2018-12-16 14:31:53 · 690 阅读 · 0 评论 -
Problem: Alpine: apk add docker ERROR: unsatisfiable constraints
Problemapk add docker ERROR: unsatisfiable constraints:...Solution// update repositoriesvi /etc/apk/repositories#/media/cdrom/apkshttp://mirrors.tuna.tsinghua.edu.cn/alpine/v3.8/mainhttp://...原创 2018-12-16 13:44:22 · 5229 阅读 · 2 评论 -
Alpine: get system info
Alpine: get system infolocalhost:~# cat /proc/versionLinux version 4.14.85-0-virt (buildozer@build-3-8-x86_64) (gcc version 6.4.0 (Alpine 6.4.0)) #1-Alpine SMP Tue Dec 4 17:35:30 UTC 2018localhost...原创 2018-12-16 13:38:21 · 343 阅读 · 0 评论 -
Command: Linux: disk space
Command: disk space[root@abc ~]# df -hFilesystem Size Used Avail Use% Mounted on/dev/vda1 40G 2.2G 36G 6% /devtmpfs 1.9G 0 1.9G 0% /devtmpfs 1.9G 0 ...原创 2018-12-15 22:30:43 · 300 阅读 · 0 评论 -
Linux: 修改指定目录下所有文件的权限
修改指定目录下所有文件的权限// 修改指定目录下所有文件的权限为全体可读、可修改、可执行# chmod -R 777 apache-tomcat-8.5.20/原创 2018-11-21 08:39:37 · 1962 阅读 · 0 评论 -
CentOS: 查看ip地址
CentOS: 查看ip地址# ip addror# ifconfig原创 2018-11-13 00:09:44 · 294 阅读 · 0 评论 -
Problem: ERROR net.sf.ehcache.Cache - Unable to set localhost. This prevents creation of a GUID...
ProblemERROR net.sf.ehcache.Cache - Unable to set localhost. This prevents creation of a GUID. Cause was: dijk-centos: dijk-centosjava.net.UnknownHostException: dijk-centos: dijk-centos…Solution...原创 2018-11-13 00:06:51 · 952 阅读 · 0 评论 -
Linux: 复制文件到当前目录
Linux: 复制文件到当前目录# ./表示当前目录$ cp /home/book/poems.tar.gz ./# 查看$ lspoems.tar.gz原创 2018-11-12 23:53:30 · 25079 阅读 · 1 评论 -
Linux: cut command
About cutRemove or “cut out” sections of each line of a file or files.cut command Syntaxcut OPTION... [FILE]...cut command options-b, --bytes=LIST Select only the bytes specified in LIST.-c, --cha转载 2015-05-28 07:50:59 · 759 阅读 · 0 评论 -
Linux: netstat command
About netstatThe netstat command is used to print network connections, routing tables, interface statistics, masquerade connections, and multicast memberships.ExamplesList All Ports (both listening and转载 2015-05-21 08:00:39 · 747 阅读 · 0 评论 -
Linux: grep command
About grepgrep prints lines of input matching a specified pattern.grep command Syntaxgrep [OPTIONS] PATTERN [FILE...]Descriptiongrep searches the named input FILEs (or standard input if no files are n转载 2015-05-28 08:05:47 · 705 阅读 · 0 评论 -
Linux: sort command
About sortSorts the lines in a text file.sort command Syntaxsort [OPTION]... [FILE]...sort command options-b, --ignore-leading-blanks Ignore leading blanks.-d, --dictionary-order Consider only b转载 2015-05-28 08:15:43 · 692 阅读 · 0 评论 -
CentOS: 解压命令tar
CentOS: 解压命令tar# 将poems.tar.gz 解压到 /home/book/tar -zxvf poems.tar.gz -C /home/book/原创 2018-11-12 23:48:31 · 646 阅读 · 0 评论 -
VirtualBox: CentOS设置共享文件夹
VirtualBox: CentOS设置共享文件夹主机选择一个文件夹作为共享文件夹,如:VboxShare虚拟机新建一个文件夹作为共享文件夹,如:/home/share挂载映射mount -t vboxsf VboxShare /home/share# 查看[如果成功则可以看到本机的文件]cd /home/sharels开机自动挂载vi ~/.bashr...原创 2018-11-12 23:38:43 · 524 阅读 · 0 评论 -
VirtualBox: Centos安装增强功能包VBoxLinuxAdditions
VirtualBox: Centos安装增强功能包VBoxLinuxAdditions预安装环境yum updateyum install gccyum install gcc-c++yum install makeyum install kernel-headersyum install kernel-develoryum updateyum groupinstall "D...原创 2018-11-12 23:20:36 · 379 阅读 · 0 评论 -
Linux: 接口调试
Linux: 接口调试Getcurl http://www.linuxidc.com/login.cgi?user=test001&password=123456Postcurl -d "user=nickwolfe&password=12345" http://www.linuxidc.com/login.cgi原创 2018-11-12 22:10:56 · 371 阅读 · 0 评论