请帮助我诊断问题。由于无法下载错误,Luarocks无法从github安装软件包。但是我可以使用curl下载相同的存档。输出如下:
/ # luarocks install say
Warning: The directory '/root/.cache/luarocks' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing /usr/local/bin/luarocks with sudo, you may want sudo's -H flag.
Installing https://luarocks.org/say-1.3-1.rockspec
Error: Error fetching file: Failed downloading https://github.com/Olivine-Labs/say/archive/v1.3-1.tar.gz - v1.3-1.tar.gz
但是,如果我执行curl -L https://github.com/Olivine-Labs/say/archive/v1.3-1.tar.gz
,则可以成功下载存档!
我也有strace输出:
connect(3, {sa_family=AF_INET, sin_port=htons(443), sin_addr=inet_addr("192.30.253.113")}, 16) = -1 EINPROGRESS (Operation in progress)
poll([{fd=3, events=POLLIN|POLLOUT}], 1, -1) = 1 ([{fd=3, revents=POLLOUT}])
getpid() = 178
getpid() = 178
getpid() = 178
clock_gettime(CLOCK_REALTIME, {tv_sec=1538486959, tv_nsec=99940500}) = 0
fcntl(3, F_GETFL) = 0x802 (flags O_RDWR|O_NONBLOCK)
fcntl(3, F_SETFL, O_RDWR|O_NONBLOCK) = 0
clock_gettime(CLOCK_REALTIME, {tv_sec=1538486959, tv_nsec=102699500}) = 0
clock_gettime(CLOCK_REALTIME, {tv_sec=1538486959, tv_nsec=103819300}) = 0
brk(0x55fb967f8000) = 0x55fb967f8000
clock_gettime(CLOCK_REALTIME, {tv_sec=1538486959, tv_nsec=105178500}) = 0
getpid() = 178
write(3, "\26\3\1\2\0\1\0\1\374\3\3\336\371\310\242[H\361X8\341W\234L;\266\321\21Da~."..., 517) = 517
read(3, 0x55fb967ea540, 7) = -1 EAGAIN (Resource temporarily unavailable)
poll([{fd=3, events=POLLIN}], 1, -1) = 1 ([{fd=3, revents=POLLIN}])
clock_gettime(CLOCK_REALTIME, {tv_sec=1538486959, tv_nsec=160629200}) = 0
read(3, "", 7) = 0
chdir("/") = 0
writev(2, [{iov_base="", iov_len=0}, {iov_base="\nError: Error fetching file: Fai"..., iov_len=121}], 2
Error: Error fetching file: Failed downloading https://github.com/Olivine-Labs/say/archive/v1.3-1.tar.gz - v1.3-1.tar.gz) = 121
writev(2, [{iov_base="", iov_len=0}, {iov_base="\n", iov_len=1}], 2