หากได้รับ The delayed auto-start flag could not be set, Error 87, The parameter is incorrect หรือ Error 5, Access is denied เมื่อพยายามตั้งค่า Windows Service เป็น Automatic (Delayed Start) บน Windows 10 บทความนี้จะช่วยแก้ไข

คอมพิวเตอร์สมัยใหม่มีประสิทธิภาพสูงขึ้น ผู้ใช้ต้องการบูทเร็วที่สุด วิธีหนึ่งคือลดโปรแกรมและบริการที่เริ่มต้นตอนบูท แต่ไม่ได้หมายความว่าต้องปิดบริการทั้งหมด บางครั้งแค่เลื่อนการเริ่มต้น (Delay) ก็พอ แต่บางคนทำไม่ได้
บางคนรายงานว่าไม่สามารถเลื่อนการเริ่มต้น Service ได้ เมื่อพยายามผ่าน Services Manager แสดงข้อผิดพลาด:
The delayed auto-start flag could not be set, Error 87, The parameter is incorrect
หรือ
The delayed auto-start flag could not be set, Error 5, Access is denied
พบบ่อยกับบริการ OneSyncSvc บทความนี้อธิบายความหมายและวิธีแก้ไขเพื่อเลื่อนการเริ่มต้นอัตโนมัติของบริการเหล่านี้
The delayed auto-start flag could not be set
เมื่อตั้งค่า Windows Service เป็น Automatic (Delayed Start) ไม่ได้ อย่าตกใจ เพราะคนอื่นเจอและแก้ได้ นี่คือวิธีแนะนำ:
- ตั้งค่า Delayed auto-start จาก Windows Registry Editor
- ใช้ PowerShell
- ลบ Service ออกจาก Service group (ไม่แนะนำ)
ก่อนเริ่ม สร้าง System Restore Point ก่อน
1] ตั้งค่า Delayed startup type จาก Windows Registry Editor
กด Windows + R เรียก Run dialog พิมพ์ Regedit กด Enter
ไปที่ตำแหน่งใน Registry:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services
หาบริการที่ต้องการเลื่อน เช่น Windows Search (WSearch)

หาคีย์ DelayedAutostart
HKLM\SYSTEM\CurrentControlSet\services\WSearch\DelayedAutostart
ค่ามีดังนี้:
- 0 – ไม่ตั้งค่า Delayed Start
- 1 – Automatic (delayed start)
ตั้งค่าเป็น 1 สำหรับ Delayed Start
ดูค่า Start บนหน้าเดียวกัน:
HKLM\SYSTEM\CurrentControlSet\services\WSearch\Start

ค่า Start DWORD:
- 2 – Automatic
- 3 – Manual
- 4 – Disabled
ถ้า Start DWORD ไม่ใช่ 2 (Automatic) ค่า DelayedAutoStart จะถูกเพิกเฉย แม้ตั้งเป็น 1 ก็ตาม
ต้องตั้งค่าเป็น 2 ในกรณีนี้
ควรช่วยได้
2] ใช้ PowerShell
กดปุ่ม Windows ค้นหา PowerShell คลิกขวา Windows PowerShell เลือก Run as Administrator
ใน PowerShell พิมพ์คำสั่งกด Enter:
Get-Service -Name ServiceName | Set-Service -StartupType AutomaticDelayedStart
NOTE: แทนที่ ServiceName ด้วยชื่อบริการที่ต้องการ
3] ลบ Service ออกจาก Service group (ไม่แนะนำ)
บริการหลายตัวเป็นสมาชิกของ Service groups หลายกลุ่มมีรายการใน ServiceGroupList ใน Registry ควบคุมลำดับการเริ่มต้น บริการหลายตัวต้องเริ่มต้นตามลำดับเฉพาะ บริการที่เป็นสมาชิกกลุ่มดังกล่าวไม่สามารถตั้งเป็น Delayed start ได้
หากเจอ Access is Denied ไม่ควรพยายามเปลี่ยน Startup type เพราะบริการเหล่านี้อยู่ใน Service Group ที่ต้องโหลดตามลำดับเฉพาะ ขึ้นอยู่กับบริการอื่น และถูกควบคุมโดย ServiceGroupList ใน Registry
แต่หากยังต้องการทำ ให้ลบค่า Group จาก Registry:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\ServiceName
NOTE: แทนที่ ServiceName ด้วยชื่อบริการที่ต้องการ
หลังทำเสร็จ รีสตาร์ทคอมพิวเตอร์เพื่อให้การเปลี่ยนแปลงมีผล
