Linux下wget下载软件小技巧以及安装jdk、tomcat与ftp服务器
一。ftp的安装
装个ftp搞了一下午,感觉以前没那么麻烦的呀,结果到晚上才发现是实验室网的问题,换连手机的热点马上可以了,真是尴尬,把基本安装步骤记录一下:
1、检查安装vsftpd软件
使用如下命令#rpm -qa |grep vsftpd可以检测出是否安装了vsftpd软件,
如果没有安装,使用YUM命令进行安装。
2、启动服务
使用vsftpd软件,主要包括如下几个命令:
启动ftp命令#service vsftpd start
停止ftp命令#service vsftpd stop
重启ftp命令#service vsftpd restart
3、vsftpd的配置
ftp的配置文件主要有三个,位于/etc/vsftpd/目录下,分别是:
ftpusers 该文件用来指定那些用户不能访问ftp服务器。
user_list 该文件用来指示的默认账户在默认情况下也不能访问ftp
vsftpd.conf vsftpd的主配置文件
4、以匿名用户为例,我们去掉配置文件vsftpd.conf 里面以下
anon_upload_enable=YES
anon_mkdir_write_enable=YES
两项前面的#号,就可以完成匿名用户的配置,此时匿名用户既可以登录上传、下载文件。记得修改配置文件后需要重启服务。
5、非匿名账户的创建与使用
vsftpd服务与系统用户是相互关联的,例如我们创建一个名为test 的系统用户,那么此用户在默认配置的情况下就可以实现登录,如图
登录后在页面创建名为“aa”的文件夹,同样我们在服务器test用户 的home目录里也可以看到相同的文件。
二。jdk的安装与wget小技巧
本来以为在centos下(其他Linux也行,ubantu不用这么麻烦)用wget直接加下载地址就可以下载想要的软件,没想到有的链接做了封装,具体细节不清楚,所以有些链接直接复制进去不行,下载下来的是乱七八糟的文档,例如oracle的jdk。
后来找到了解决方法,如下:
wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" download.oracle.com/otn-pub/java/jdk/8u111-b14/jdk-8u111-linux-x64.tar.gz
把后面的链接改为你要下载的文件的版本。即可。
三。配置
[root@bogon jre]# rpm -qa|grep jdk
java-1.8.0-openjdk-headless-1.8.0.65-3.b17.el7.x86_64
java-1.7.0-openjdk-1.7.0.91-2.6.2.3.el7.x86_64
java-1.7.0-openjdk-headless-1.7.0.91-2.6.2.3.el7.x86_64
java-1.8.0-openjdk-1.8.0.65-3.b17.el7.x86_64
卸载命令
[root@bogon jre]# yum -y remove java-1.8.0-openjdk-headless-1.8.0.65-3.b17.el7.x86_64
卸载完成之后Java命令不被识别
[root@bogon lib]# java -version
bash: java: command not found...
下载好之后把文件移动到/usr/lib/jvm下(习惯),然后进行解压:
解压到安装目录
[root@bogon software]# tar -zxvf jdk-8u101-linux-x64.tar.gz -C /usr/local/java/
安装完毕之后在/etc/profile文件末尾添加
[root@bogon software]# vim /etc/profile
export JAVA_HOME=/usr/local/java/jdk1.8.0_101
export JRE_HOME=${JAVA_HOME}/jre
export CLASSPATH=.:${JAVA_HOME}/lib:${JRE_HOME}/lib
export PATH=${JAVA_HOME}/bin:$PATH
使/etc/profile生效
[root@bogon jdk1.8.0_101]# source /etc/profile
检测安装是否成功
[root@bogon jdk1.8.0_101]# java -version
java version "1.8.0_101"
Java(TM) SE Runtime Environment (build 1.8.0_101-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.101-b13, mixed mode)
[root@bogon jdk1.8.0_101]# javac
Usage: javac <options> <source files>
where possible options include:
-g Generate all debugging info
-g:none Generate no debugging info
-g:{lines,vars,source} Generate only some debugging info
-nowarn Generate no warnings
-verbose Output messages about what the compiler is doing
-deprecation Output source locations where deprecated APIs are used
-classpath <path> Specify where to find user class files and annotation processors
-cp <path> Specify where to find user class files and annotation processors
-sourcepath <path> Specify where to find input source files
-bootclasspath <path> Override location of bootstrap class files
-extdirs <dirs> Override location of installed extensions
-endorseddirs <dirs> Override location of endorsed standards path
-proc:{none,only} Control whether annotation processing and/or compilation is done.
-processor <class1>[,<class2>,<class3>...] Names of the annotation processors to run; bypasses default discovery process
-processorpath <path> Specify where to find annotation processors
-parameters Generate metadata for reflection on method parameters
-d <directory> Specify where to place generated class files
-s <directory> Specify where to place generated source files
-h <directory> Specify where to place generated native header files
-implicit:{none,class} Specify whether or not to generate class files for implicitly referenced files
-encoding <encoding> Specify character encoding used by source files
-source <release> Provide source compatibility with specified release
-target <release> Generate class files for specific VM version
-profile <profile> Check that API used is available in the specified profile
-version Version information
-help Print a synopsis of standard options
-Akey[=value] Options to pass to annotation processors
-X Print a synopsis of nonstandard options
-J<flag> Pass <flag> directly to the runtime system
-Werror Terminate compilation if warnings occur
@<filename> Read options and filenames from file
四。tomcat的安装
直接用wget +tomcat的官方镜像网站就可以下载,把下载好的文件移动到/usr/local目录下。进入其中的bin目录 运行./startup.sh即可。
Linux下wget下载软件小技巧以及安装jdk、tomcat与ftp服务器的更多相关文章
- ubuntu下安装jdk,tomcat,mysql,ftp,telnet,svn
需求分析:自己弄了个小网站,想放到云服务器上,同时把自己积累的代码也放上去,服务器上的文件可以简单的在windows上查看,也可以方便的通过windows连接linux服务器. 解决:运行网站要用到j ...
- Linux下wget下载整个FTP目录(含子目录)--转载
wget -nH -m --ftp-user=your_username --ftp-password=your_password ftp://your_ftp_host/* 解释:-nH:不创建以主 ...
- Linux下的XAMPP基本配置技巧(设置虚拟主机、添加FTP账户等)
xampp安装好之后就只有一个默认站点及一个默认nobody的ftp账户,这显然不符合我们平时的需求了,那么下面就来讲一下如何设置并管理多个虚拟主机及ftp账户了,至于xampp的安装不在此讨论范围, ...
- CentOS 6.x下wget 下载提示 Unable to locally verify the issuer’s authority 完美解决方案
CentOS 6.x下wget 下载提示 Unable to locally verify the issuer’s authority 完美解决方案 栏目:Linux 作者:小天 点击: 1,453 ...
- Linux下校验下载文件的完整性(MD5,SHA1,PGP)
查看: Linux下校验下载文件的完整性(MD5,SHA1,PGP) http://blog.useasp.net/archive/2014/03/29/use-md5-sha1-or-pgp-to- ...
- Linux下提权常用小命令
有些新手朋友在拿到一个webshell后如果看到服务器是Linux或Unix操作系统的就直接放弃提权,认为Linux或Unix下的提权很难,不是大家能做的,其实Linux下的提权并没有很多人想象的那么 ...
- Linux下Oracle11G RAC报错:在安装oracle软件时报file not found一例
Linux下Oracle11G RAC报错:在安装oracle软件时报file notfound一例 1.现象 之前安装一切都比較顺利,安装oracle软件时,进度到30%时报错:file not f ...
- linux 使用wget下载https连接地址cannot verify github.com's certificate
使用linux的wget下载时候会出现网站没有证书警告的问题, 例如下载git时,可以使用wget https://github.com/git/git/archive/v2.3.0.zip --no ...
- linux下如何查看mysql、apache是否安装,并卸载
--linux下如何查看mysql.apache是否安装,并卸载? http://blog.163.com/dengxiuhua126@126/blog/static/1186077720137311 ...
随机推荐
- [转]Linux安装前配置操作记录
转至:http://m.blog.csdn.net/weixin_35884835/article/details/52385077 1.修改用户的SHELL的限制,修改/etc/security/l ...
- 判断本地是否存在Jquery文件,如果不存在则使用CDN加速的Jquery文件
<script>//判断是否成功将Jquery库引入,如果没有成功引入则引入本地Jquery库if (typeof jQuery == 'undefined') {document.wri ...
- fopen_s()
原型:errno_t fopen_s( FILE** pFile, const char *filename, const char *mode ); 例子: char *filePath=&q ...
- echarts设置地图大小比例,大小设置
设置地图大小可通过以下属性设置: geo.aspectScale number [ default: 0.75 ] 这个参数用于 scale 地图的长宽比. 最终的 aspect 的计算方式是:geo ...
- codevs3027(dp)
题目链接: http://codevs.cn/problem/3027/ 题意: 中文题目诶~ 思路: dp 先给所有线段按照右端点值升序 sort 一下, 用 dp[i] 存储以第 i 条线段结尾的 ...
- 洛谷P3901 数列找不同(莫队)
传送门 我不管我不管我就是要用莫队 直接用莫队裸上 //minamoto #include<iostream> #include<cstdio> #include<alg ...
- v-touch使用方法以及在项目中遇到的问题
上篇博客中我记得还有一个坑没有解决好,在这篇博客中详细说明一下. 在 https://github.com/dreamITGirl/vuepageturn 我的这个代码库里,更新到2.1版本. 目前解 ...
- 查看ip常见命令...
1.获取ip Unix用户可以在命令提示符中输入ifconfig来获取. 使用Windows的用户,请尝试使用 ipconfig 命令.
- window安装配置 zookeeper 单机模式
1.zookeeper简单介绍 zookeeper是一个分布式的,开放源码的分布式应用程序协调服务,我所了解到的主要的使用场景有两个 (1).微服务注册中心(Dubbo较常用Zookeeper做注册中 ...
- 使用gifplayer操作gif的方法
使用的工具--gifplayer 基本用法: 1.安装 git clone https://github.com/rubentd/gifplayer.git 2.添加一张gif预览的图片 <im ...