Added root check for sudo