473,326 Members | 2,099 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,326 software developers and data experts.

Shell script to start a asp.net website/service

40
Hi,

I am new to shell scripts.Want to know the shell script for starting and stopping a asp.net website and service in a server.Ex: my website name is "website1" and service name is "Service1". I want to write a shell script for starting and stopping website1 and Service1 in a server say "aaa".

Thanx in advance,
Blacky
Oct 4 '10 #1
7 3010
ashitpro
542 Expert 512MB
Where have you deployed your asp.net website?
I mean operating system? web server etc?
Oct 4 '10 #2
Blacky
40
These are the details,

OS: Windows 2003 server
Webserver : IIS 7.0
Oct 4 '10 #3
ashitpro
542 Expert 512MB
if it is windows machine, how are you planning to run shell scripts?

using cygwin?

Or are you talking about batch scripts?
Oct 4 '10 #4
Blacky
40
using uc4 tool. i can call that script in uc4
Oct 4 '10 #5
ashitpro
542 Expert 512MB
In typical linux system, you will need to write a script with start/stop switches, then invoke the relative service binaries from respective functions.

http://www.cyberciti.biz/tips/linux-...p-service.html

Now, as you are using uc4, basic script structure should be same, the tricky part is to locating and invoking the service binaries. I am quite sure that you will have to refer its documentation.

On windows system you can use 'net' family command to manage your services.

http://technet.microsoft.com/en-us/l...8WS.10%29.aspx

I am not sure if you can execute such commands in so called shell scripts. There must be some way, specific to uc4. Unfortunately, there is nothing much available on google to help you.
Oct 4 '10 #6
Blacky
40
Thanx but where do we specify the server details in the shell scripts
Oct 4 '10 #7
ashitpro
542 Expert 512MB
In first link that I'd sent you, look for start() function.
They have shown how to invoke foo service. This is linux specific.

Check this link:

http://www.tech-faq.com/using-iis-co...anage-iis.html

It has shown how to start/stop iis and websites from command line.

All you have to do is write these command in start() functions.
Oct 4 '10 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

7
by: Robin Becker | last post by:
I wonder if this is the right way to write a medusa(asyncore) server with the win32all framework. Other example services seem to create an event to pass the stop signal from SvcStop into a separate...
8
by: Russ Green | last post by:
I'm using a Setup Project in VB.NET 2003 Standard to install a windows service application. I would like this installer to start the service after install. How do I do that? Thanks, Russ
3
shahjapan
by: shahjapan | last post by:
Hello, I want to start a server at the linux system boot up (UBUNTU 7.04 ) I have used start-stop-daemon command in my shell script for that. I have written my shell script path in...
9
by: niteck07 | last post by:
I am using following shell script to ftp files to another server but this is failing as the shell script changes the user name for the ftp login the correct user name is 'ag\invprint' which the...
0
by: sagarbsa | last post by:
Hii, I have a shell script to create a small dialog box to select options and give the output. But it is exiting the script without displaying anything. Can anyone help me with this cat > smenu #...
3
by: telduivel | last post by:
Can someone please help me with this: I have a python script, that at some point calls a linux bash script (.sh). Starting the shell script is the last thing my python script needs to do, so I...
1
by: iamforsecurity | last post by:
Hi, I am a newbie in Shell Script. I am trying to open 10 new sessions,each session running on a separate thread. For each session, I open a new xterm, go to a particular directory and run a...
5
by: inetquestion | last post by:
I am looking for a web interface for shell commands or shell scripts. Does anyone know of any exexisting php scripts which would solve this requirement? PHP form accepts input from a user, then...
16
by: pereges | last post by:
Do you see anything wrong about this method ? For eg. I write a shell script a.sh containing : cc -o test file1.c file2.c file3.c and then execute the shell script ( sh a.sh) to compile and...
7
by: Samuel A. Falvo II | last post by:
I have a shell script script.sh that launches a Java process in the background using the &-operator, like so: #!/bin/bash java ... arguments here ... & In my Python code, I want to invoke...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.