我是Apache安装的新手。当我尝试通过命令行启动Apache服务器时 $ sudo ./apachectl开始 我收到消息:
import random
file = open("C:\\Users\\nikol\\Downloads\\ThreeLetters.txt","w+",encoding =
"utf-8")
word = []
char = 0
wordloop = 0
words = []
currentword = ""
while wordloop < 46656:
for n in range(3):
char = random.randint(1,36)
if char == 1:
word.append("a")
if char == 2:
word.append("b")
if char == 3:
word.append("c")
if char == 4:
word.append("d")
if char == 5:
word.append("e")
if char == 6:
word.append("f")
if char == 7:
word.append("g")
if char == 8:
word.append("h")
if char == 9:
word.append("i")
if char == 10:
word.append("j")
if char == 11:
word.append("k")
if char == 12:
word.append("l")
if char == 13:
word.append("m")
if char == 14:
word.append("n")
if char == 15:
word.append("o")
if char == 16:
word.append("p")
if char == 17:
word.append("q")
if char == 18:
word.append("r")
if char == 19:
word.append("s")
if char == 20:
word.append("t")
if char == 21:
word.append("u")
if char == 22:
word.append("v")
if char == 23:
word.append("w")
if char == 24:
word.append("x")
if char == 25:
word.append("y")
if char == 26:
word.append("z")
if char == 27:
word.append("0")
if char == 28:
word.append("1")
if char == 29:
word.append("2")
if char == 30:
word.append("3")
if char == 31:
word.append("4")
if char == 32:
word.append("5")
if char == 33:
word.append("6")
if char == 34:
word.append("7")
if char == 35:
word.append("8")
if char == 36:
word.append("9")
for n in range(len(word)):
currentword = currentword + word[n]
word = []
words.append(currentword)
currentword = ""
wordloop += 1
words = sorted(words)
for n in range(len(words)):
file.write(str(words[n]) + ",")
file.close()
我问在哪里设置“ ServerName”。我打开了[httpd.conf]文件以将[DocumentRoot]目录路径编辑为计算机的主目录,因为还写入了[httpd.conf]文件[ServerName www.example.com:80],我应该编辑此[ ServerName作为“ localhost”]来禁止显示上述消息,并在没有此消息的情况下将apache服务器作为localhost启动。
请提出建议,我已经阅读了有关此问题的信息,但理解不正确。