Debmirr 错误

Debmirr 错误

我按照以下指南设置 debmirrorhttps://help.ubuntu.com/community/Debmirror。我将文件更改为转到外部驱动器并将其设置为下载 Focal 和 Hirsute。Debmirror 完成且没有错误,但当我尝试将计算机指向它时出现错误,而当我尝试 apt-get update 时出现错误。

错误消息:
存储库“http://192.168.1.42/ubuntu hirsute Release”没有 Release 文件。从这样的存储库进行更新无法安全地进行,因此默认情况下是禁用的。有关存储库创建和用户配置详细信息,请参阅 apt-secure(8) 手册页。

我哪里做错了?


文件下载至此处

/mnt/USBHDD/mirrors/ubuntu_repository
├── dists
│   ├── focal
│   ├── focal-security
│   ├── focal-updates
│   ├── hirsute
│   ├── hirsute-security
│   └── hirsute-updates
├── pool
│   ├── main
│   ├── multiverse
│   ├── restricted
│   └── universe
└── project
    └── trace

对于 Apache,我符号链接到 /var/www/ubuntu Tree 看起来与上面的相同。

这是我的 sh 脚本

#!/bin/bash

# Arch=         -a      # Architecture. For Ubuntu can be i386, powerpc or amd64.
# sparc, only starts in dapper, it is only the later models of sparc.
# For multiple  architecture, use ",". like "i386,amd64"

arch=amd64,i386

# Minimum Ubuntu system requires main, restricted
# Section=      -s      # Section (One of the following - main/restricted/universe/multiverse).
# You can add extra file with $Section/debian-installer. ex: main/debian-installer,universe/debian-installer,multiverse/debian-installer,restricted/debian-installer


section=main,restricted,universe,multiverse

# Release=      -d      # Release of the system (, focal ), and the -updates and -security ( -backports can be added if desired)
# List of updated releases in: https://wiki.ubuntu.com/Releases
# List of sort codenames used: http://archive.ubuntu.com/ubuntu/dists/

release=focal,focal-security,focal-updates,hirsute,hirsute-security,hirsute-updates

# Server=       -h      # Server name, minus the protocol and the path at the end
# CHANGE "*" to equal the mirror you want to create your mirror from. au. in Australia  ca. in Canada.
# This can be found in your own /etc/apt/sources.list file, assuming you have Ubuntu installed.

server=archive.ubuntu.com

# Dir=          -r      # Path from the main server, so http://my.web.server/$dir, Server dependant

inPath=/ubuntu

# Proto=        --method=       # Protocol to use for transfer (http, ftp, hftp, rsync)
# Choose one - http is most usual the service, and the service must be available on the server you point at.
# For some "rsync" may be faster.

proto=rsync

# Outpath=              # Directory to store the mirror in
# Make this a full path to where you want to mirror the material.

outPath=/mnt/USBHDD/mirrors/ubuntu_repository

# The --nosource option only downloads debs and not deb-src's
# The --progress option shows files as they are downloaded
# --source \ in the place of --no-source \ if you want sources also.
# --nocleanup  Do not clean up the local mirror after mirroring is complete. Use this option to keep older repository

# Start script

debmirror       -a $arch \
                --no-source \
                --check-gpg \
                --checksums \
                -s $section \
                -h $server \
                -d $release \
                -r $inPath \

答案1

经过大量的网络搜索,我找到了问题的答案。
问题出在 Apache 的默认位置。

指南将其列为 /var/www/ubuntu

应该是 /var/www/html/Ubuntu

经过这样的改变之后,我的镜子就可以正常工作了。

拼图中缺失的那一块位于:
已创建 apt-mirror 但无法从 localhost/ubuntu 浏览
感谢 Arronical

相关内容