---
title: "Linux下停止sendmail服务"
author: "cnaning"
date: "2010-12-18T07:41:30Z"
tags: []
categories: ["操作系统"]
slug: "linux-sendmail"
draft: false
lastmod: "2010-12-18T07:41:30Z"
id: 846089
url: "https://cnaning.iteye.com/blog/846089"
---

每次LINUX启动到sendmail时候就不动了，等了好久才进入系统，很不爽，就把sendmail进程停了，HOHO

　　1.执行命令service sendmail stop

　　2.执行命令：chkconfig --list sendmail

　　sendmail 0:off 1:off 2:on 3:on 4:on 5:on 6:off

　　表明sendmail在level在2.3.4.5时是自动开启的。而一般系统设置为中间level(3)，因此每次机器重启，sendmail会自动重启。

　　chkconfig --level 2345 sendmail off

　　这样以来，sendmail在2、3、4、5级别也关闭了。这样，机器重启之后，sendmail也不会重启了执行命令

　　或者直接的方法：  
　　执行命令#ntsysv取消sendmail选项就行。