While creating a web application on MOSS2007 environment i have been getting this error.
I didn't find out any errors related to this in Logs file.
Finally i did two steps
1)Restart the SharePoint Timer Services
Still i am getting this error...
Finally restart the server...
I know the last one is actually ridiculous but it helped.(My box RAM is 1GB,2 users are using this through remotely and N/W IP is slow and etc)
Trust me it should work!!