v2fly / fhs-install-v2ray

Bash script for installing V2Ray in operating systems such as Debian / CentOS / Fedora / openSUSE that support systemd
GNU General Public License v3.0
6.29k stars 1.46k forks source link

install v2ray without port and uuid #190

Closed beyond911 closed 3 years ago

beyond911 commented 3 years ago

The version is Ubuntu Server 20.04 LTS . The code is following.

root@VM-0-10-ubuntu:~# bash <(curl -L https://raw.githubusercontent.com/v2fly/fhs-install-v2ray/master/install-release.sh) % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 21113 100 21113 0 0 859k 0 --:--:-- --:--:-- --:--:-- 859k info: Installing V2Ray v4.33.0 for x86_64 Downloading V2Ray archive: https://github.com/v2fly/v2ray-core/releases/download/v4.33.0/v2ray-linux-64.zip % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 644 100 644 0 0 4842 0 --:--:-- --:--:-- --:--:-- 4878 100 11.8M 100 11.8M 0 0 3424k 0 0:00:03 0:00:03 --:--:-- 4120k Downloading verification file for V2Ray archive: https://github.com/v2fly/v2ray-core/releases/download/v4.33.0/v2ray-linux-64.zip.dgst Reading package lists... Done Building dependency tree
Reading state information... Done Suggested packages: zip The following NEW packages will be installed: unzip 0 upgraded, 1 newly installed, 0 to remove and 104 not upgraded. Need to get 169 kB of archives. After this operation, 593 kB of additional disk space will be used. Get:1 http://mirrors.tencentyun.com/ubuntu focal/main amd64 unzip amd64 6.0-25ubuntu1 [169 kB] Fetched 169 kB in 0s (2,999 kB/s) Selecting previously unselected package unzip. (Reading database ... 77181 files and directories currently installed.) Preparing to unpack .../unzip_6.0-25ubuntu1_amd64.deb ... Unpacking unzip (6.0-25ubuntu1) ... Setting up unzip (6.0-25ubuntu1) ... Processing triggers for mime-support (3.64ubuntu1) ... Processing triggers for man-db (2.9.1-1) ... info: unzip is installed. info: Extract the V2Ray package to /tmp/tmp.h8hF7Bst61 and prepare it for installation. rm: cannot remove '/etc/systemd/system/v2ray.service.d/10-donot_touch_multi_conf.conf': No such file or directory rm: cannot remove '/etc/systemd/system/v2ray@.service.d/10-donot_touch_multi_conf.conf': No such file or directory info: Systemd service files have been installed successfully! warning: The following are the actual parameters for the v2ray service startup. warning: Please make sure the configuration file path is correctly set.

/etc/systemd/system/v2ray.service

[Unit] Description=V2Ray Service Documentation=https://www.v2fly.org/ After=network.target nss-lookup.target

[Service] User=nobody CapabilityBoundingSet=CAP_NET_ADMIN CAP_NET_BIND_SERVICE AmbientCapabilities=CAP_NET_ADMIN CAP_NET_BIND_SERVICE NoNewPrivileges=true ExecStart=/usr/local/bin/v2ray -config /usr/local/etc/v2ray/config.json Restart=on-failure RestartPreventExitStatus=23

[Install] WantedBy=multi-user.target

/etc/systemd/system/v2ray.service.d/10-donot_touch_single_conf.conf

In case you have a good reason to do so, duplicate this file in the same directory and make your customizes there.

Or all changes you made will be lost! # Refer: https://www.freedesktop.org/software/systemd/man/systemd.unit.html

[Service] ExecStart= ExecStart=/usr/local/bin/v2ray -config /usr/local/etc/v2ray/config.json

installed: /usr/local/bin/v2ray installed: /usr/local/bin/v2ctl installed: /usr/local/share/v2ray/geoip.dat installed: /usr/local/share/v2ray/geosite.dat installed: /usr/local/etc/v2ray/config.json installed: /var/log/v2ray/ installed: /var/log/v2ray/access.log installed: /var/log/v2ray/error.log installed: /etc/systemd/system/v2ray.service installed: /etc/systemd/system/v2ray@.service removed: /tmp/tmp.h8hF7Bst61 info: V2Ray v4.33.0 is installed. You may need to execute a command to remove dependent software: apt purge curl unzip Please execute the command: systemctl enable v2ray; systemctl start v2ray

IceCodeNew commented 3 years ago

Describe your question/request.

beyond911 commented 3 years ago

When I install v2ray server in the ubuntu 20.04 LTS . But there is not port and uuid. Can you understand me ?

beyond911 commented 3 years ago

Describe your question/request. I do it as the following tutorial. https://umaint.github.io/2019/01/05/v2ray-windows/

If it is successful , the port and uuid are following as screen. image But there are not the port and uuid(the Following screen is mine.).

image

IceCodeNew commented 3 years ago

I do it as the following tutorial. umaint.github.io/2019/01/05/v2ray-windows

This tutorial only shows the execution result of the deprecated official installation script. Not like this project, it will provide a set of configuration that gives users an out-of-the-box experience. However, as v2ray has undergone tremendous development, providing a configuration that could suit many users becomes impossible. Based on the description of this issue, you did not counter any problem. It's just the outdated tutorial misleading you. Write your configuration that suits your use case is all you need to do. And also, remember to refer to the official Wiki this time. https://www.v2fly.org/en_US/

beyond911 commented 3 years ago

I do it as the following tutorial. umaint.github.io/2019/01/05/v2ray-windows

This tutorial only shows the execution result of the deprecated official installation script. Not like this project, it will provide a set of configuration that gives users an out-of-the-box experience. However, as v2ray has undergone tremendous development, providing a configuration that could suit many users becomes impossible. Based on the description of this issue, you did not counter any problem. It's just the outdated tutorial misleading you. Write your configuration that suits your use case is all you need to do. And also, remember to refer to the official Wiki this time. https://www.v2fly.org/en_US/

Thanks. The issue is solved now .