Search Results

Search found 28350 results on 1134 pages for 'command switch'.

Page 31/1134 | < Previous Page | 27 28 29 30 31 32 33 34 35 36 37 38  | Next Page >

  • Need to copy remotely hosted file vis Shell Command

    - by pnm123
    Hello, There is a file that hosted remotely on a server that is not supporting Shell Access. I bought a new server that supports Shell Access so now I want to copy a file that is on the non-supporting server to new server via a Shell Command using Putty. File url is like this http://www.domain.com/file.gzip and it is username/password protected. If I be more specified, I want to copy a backup of a home directory from cPanel to my new server via Shell command. I have done this few months ago but I don't remember it now and also I failed to google it. Thank you, Prasad

    Read the article

  • Command Line arguments - PHP

    - by Chaitanya
    Am trying the following php script which finds out the maximum between 2 numbers, it accepts the arguments through command line. I check whether the input is provided right, based on the number of command line arguments. <?php function larger($arg1,$arg2) { return max($arg1,$arg2); } if($argc > 3 || $argc < 3) print 'Invalid Arguments'; exit(1); if($argc==3) { print larger($argv[1],$argv[2]); } ?> Am executing the program in a windows system, and the file resides in xampp/php directory. While executing I don't get any output neither any error report. How do i check whether am right or wrong?

    Read the article

  • Developing "Command Line" in .NET?

    - by Sergey Malyan
    Imagine a "search box" on the right top side of the UI Windows Application. When user types a desired action, a matching functionality is executed. Screen gets opened, or action gets performed. For example: user types "create" and intellisence offered next word options "client"/"product", user picks "client", and "Create New Client" screen opens up. So what I am looking for if there is a framework support for this. I assume that framework shall bind together text commands names, commands and show in intellisense. Same framework possibly could have been used in alternative "Command Line interface". I recall Microsoft had some recent framework that helps to setup "command Line Interface" environmental. It is hard to search on web for this keywords, so relying on intelligent help from you guys. Thanks in advance.

    Read the article

  • VB6 ADO Command to SQL Server

    - by Emtucifor
    I'm getting an inexplicable error with an ADO command in VB6 run against a SQL Server 2005 database. Here's some code to demonstrate the problem: Sub ADOCommand() Dim Conn As ADODB.Connection Dim Rs As ADODB.Recordset Dim Cmd As ADODB.Command Dim ErrorAlertID As Long Dim ErrorTime As Date Set Conn = New ADODB.Connection Conn.ConnectionString = "Provider=SQLOLEDB.1;Integrated Security=SSPI;Initial Catalog=database;Data Source=server" Conn.CursorLocation = adUseClient Conn.Open Set Rs = New ADODB.Recordset Rs.CursorType = adOpenStatic Rs.LockType = adLockReadOnly Set Cmd = New ADODB.Command With Cmd .Prepared = False .CommandText = "ErrorAlertCollect" .CommandType = adCmdStoredProc .NamedParameters = True .Parameters.Append .CreateParameter("@ErrorAlertID", adInteger, adParamOutput) .Parameters.Append .CreateParameter("@CreateTime", adDate, adParamOutput) Set .ActiveConnection = Conn Rs.Open Cmd ErrorAlertID = .Parameters("@ErrorAlertID").Value ErrorTime = .Parameters("@CreateTime").Value End With Debug.Print Rs.State ' Shows 0 - Closed Debug.Print Rs.RecordCount ' Of course this fails since the recordset is closed End Sub So this code was working not too long ago but now it's failing on the last line with the error: Run-time error '3704': Operation is not allowed when the object is closed Why is it closed? I just opened it and the SP returns rows. I ran a trace and this is what the ADO library is actually submitting to the server: declare @p1 int set @p1=1 declare @p2 datetime set @p2=''2010-04-22 15:31:07:770'' exec ErrorAlertCollect @ErrorAlertID=@p1 output,@CreateTime=@p2 output select @p1, @p2 Running this as a separate batch from my query editor yields: Msg 102, Level 15, State 1, Line 4 Incorrect syntax near '2010'. Of course there's an error. Look at the double single quotes in there. What the heck could be causing that? I tried using adDBDate and adDBTime as data types for the date parameter, and they give the same results. When I make the parameters adParamInputOutput, then I get this: declare @p1 int set @p1=default declare @p2 datetime set @p2=default exec ErrorAlertCollect @ErrorAlertID=@p1 output,@CreateTime=@p2 output select @p1, @p2 Running that as a separate batch yields: Msg 156, Level 15, State 1, Line 2 Incorrect syntax near the keyword 'default'. Msg 156, Level 15, State 1, Line 4 Incorrect syntax near the keyword 'default'. What the heck? SQL Server doesn't support this kind of syntax. You can only use the DEFAULT keyword in the actual SP execution statement. I should note that removing the extra single quotes from the above statement makes the SP run fine. ... Oh my. I just figured it out. I guess it's worth posting anyway.

    Read the article

  • Shell - How to find directory of some command?

    - by Gabriel L. Oliveira
    I know that when you are on shell, the only commands that can be used are the ones that can be found on some directory set on PATH. Even I don't know how to see what dirs are on my PATH variable (and this is another good question that could be answered), what I'd like to know is: I come to shell and write: $ lshw I want to know a command on shell that can tell me WHERE this command is located. In other words, where this "executable file" is located? Something like: $ location lshw /usr/bin Anyone?

    Read the article

  • WNDR3700 Router + Cisco SG200-08 + LACP + Dual Uplink

    - by kobaltz
    Background I have a storage server that has several virtual machine images stored on them. I would store them locally, but I have limited space on my desktop (using SSD storage). I would like to increase the bandwidth between the desktop and the storage server by using two NICs on each computer. My original configuration allowed about 55MBps between the desktop and storage server. This storage server also has several TBs of documents, pictures, movies, vms, and ISO/programs. The storage server has 8 1.5TB hard drives in a RAID 10 configuration with a hardware RAID controller. The benchmarks on the RAID 10 are about 300MBps. Configuration In short, I am trying to bridge my switch and router. The switch is a small 8 port Cisco smart switch that supports 802.3ad LACP. I have two computers plugged into the switch, each with 2 Intel Gigabit NICs. The first computer is a Windows 7 machine that has the Intel ANS software installed. I have LACP configured with the computer and now show 3 NICs (2 Physical + 1 TEAM Virtual @ 2Gbps). It looks like this computer is configured correctly. I trunked the two ports that this computer is plugged into with the switch's web interface. The second computer is a homebrew storage box running debian. I also have the bonding enabled on this machine and the switch configured with LACP. Without having the WNDR3700 router in the picture yet, I am able to communicate between the Windows 7 machine and the debian box since they both have static IP addresses. With LACP enabled on both machines I am getting about 106-108MBps speeds. Issue I plug in a network cable from the switch into the router and enable DHCP on the desktop. I saw no need to have a static address on the desktop. My transfer rates are still from 106MBps-108MBps. While this is still a boost, I am trying to figure out how to get about 140-180MBps. I am thinking that I need to increase the bandwidth from the router to the switch. My switch allows 4 groups for port trunking. I plugged in a second network cable from the router to the switch. My question is, what is the proper way to fix this issue. Should I port trunk the two ports that are going from the switch to the router? Keep in mind that the router is a WNDR3700 and is unsure whether or not it supports LACP. I do have OpenWRT installed on the router, but it still wasn't clear in any documentation that I found if it supported 802.3ad LACP standards. I am also wondering if there needs to be anything changed within the Cisco settings. [Edit] - Corrected some numbers, wasn't really paying attention. It looks like the speeds though at least two NICs are bonded with LACP is still reaching the max bandwidth of one port. Is there a way to configure the switch so that I can increase this bandwidth? Also, on the storage server, I had a couple of extra NICs laying around and threw them on there as well. Another EDIT and More Findings I happened to look at the traffic of each individual NIC and think that I see the problem. I tested with a simple transfer for a 4GB file. I noticed that only one of the NICs was taking the load of the traffic. I then copied the file back to the Storage Server and noticed that the other NIC was sending out the traffic. I have 802.3ad LACP enabled on the two NICs and I see that it gets enabled dynamically on the switch's interface. Should I be using Static Link Aggregation?

    Read the article

  • starting .net application from command prompt is having issue when path is in SHORTNAME

    - by ioWint
    when we start our .net application using a double click on the explorer or from command prompt where your folder path is proper full name then there is no issue at all. But when you start it from command prompt with the path being a Shortname involving a ~ the application behaves weird. IF is entering condition though the condition evaluates to FALSE in quick watch. Accessing a value of a variable in quick watch and immediate window shows value. but when you use it to assign to another variable in code, it returns NULL / no value. another observation: when you attach Visual studio to debug the app, and when you go about "Set as next statement" visual studio is giving options to select which dll to work up on. i have never seen this prompt before!

    Read the article

  • Concatenate text files with Windows command line, dropping leading lines

    - by James
    I need to concatenate some relatively large text files, and would prefer to do this via the command line. Unfortunately I only have Windows, and cannot install new software. type file1.txt file2.txt > out.txt allows me to almost get what I want, but I don't want the 1st line of file2.txt to be included in out.txt. I have noticed that more has the +n option to specify a starting line, but I haven't managed to combine these to get the result I want. I'm aware that this may not be possible in Windows, and I can always edit out.txt by hand to get rid of the line, but is there a simple way of doing it from the command line?

    Read the article

  • Haskell: reading multiple command line arguments

    - by Survot
    Hi all, Okay, so I am making a program in Haskell that needs to change certain words based on two command line arguments. I have made the replace function and everything works great, but I am stumped getting it to work with command line arguments. Here is the main code: (replace function not included) main = do text <- getContents (command1:command2:_) <- getArgs putStrLn (replace (read command1) (read command2) text) So for intstance in the terminal I want to be able to type something like: "--- cat textfile.txt | ./replace oldword newword" I know this code is close since I have seen others do it this way. O_o Thanks for any help

    Read the article

  • Batch file crashes when double clicked, but passes from command prompt

    - by devinb
    I have a batch file that was crashing when executing from windows explorer. I opened a command prompt and navigated to the file, but when I executed it there it did not crash. I identified the line that was crashing. SET list =(Company.Framework^ Company.SharePoint.Lists.News^ Company.SharePoint.WebControls^ Company.SharePoint.WebParts.NewsList^ Company.SharePoint.WebParts.RedirectWebPart^ Company.SharePoint.WebParts.IFrameWebPart^ Company.SharePoint.WebParts.ItemRotatorWebPart^ Company.SharePoint.WebParts.InteractiveMapWebPart^ Company.SharePoint.WebParts.SiteMapWebPart^ Company.SharePoint.Branding.PrettyUnicorns) ::Do stuff ::Failure occurs here FOR %%F in %list% DO ( ::Doesn't matter what is in here ECHO Woo! ) Is any reason why a batch file would behave differently from Windows Explorer vs Command Prompt?

    Read the article

  • tools for creating user-friendly command-line prompt?

    - by davka
    I notice that some programs (e.g. sqlite, mysql client) provide a command-line prompt that is very similar in capabilities to the bash's, including: line editing with left and right arrows, delete, insert, ^K, etc. history browsing with up and down arrows ^R for reverse i-search in command history which make me think that they are using the same toolset for this. I'd like to create a prompt with similar capabilities in my program, which tools can I use? I prefer it to have the same functionality as in bash, so that the users would be familiar with it.

    Read the article

  • command design pattern usage

    - by sagie
    Hi. I've read 3 descriptions of the command design pattern: wikipedia, dofactory and source making. In all of them, the UML shows a relation between the client to the receiver & the concrete command, but no relation to the invoker. But in all 3 examples the client is the one that initiates the invoker and call its Execute method. I think that should be a relation to the invoker as well. Am I missing somthing in here? Maybe even a basic UML knowladge?

    Read the article

  • Need to copy remotely hosted file via Shell Command

    - by pnm123
    There is a file that hosted remotely on a server that is not supporting Shell Access. I bought a new server that supports Shell Access so now I want to copy a file that is on the non-supporting server to new server via a Shell Command using Putty. File url is like this http://www.domain.com/file.gzip and it is username/password protected. To be more specific, I want to copy a backup of a home directory from cPanel to my new server via Shell command. I have done this few months ago but I don't remember it now and also I failed to Google it.

    Read the article

  • How to animate the command line?

    - by The.Anti.9
    I have always wondered how people update a previous line in a command line. a great example of this is when using the wget command in linux. It creates an ASCII loading bar of sorts that looks like this: [======                    ] 37% and of course the loading bar moves and the percent changes, But it doesn't make a new line. I cannot figure out how to do this. Can someone point me in the right direction?

    Read the article

  • How do you reset a USB device from the command line?

    - by Casey
    Is it possible to reset the connection of a USB device, without physically disconnecting/connecting from the PC? Specifically, my device is a digital camera. I'm using gphoto2, but lately I get "device read errors", so I'd like to try to do a software-reset of the connection. From what I can tell, there are no kernel modules being loaded for the camera. The only one that looks related is usbhid.

    Read the article

  • Have to run auto-negotiate between clients and switch - "old" switch works fine - "new" switch results in "port flapping"?

    - by ConfusedAboutSwitching
    I need some help understanding a problem we're having at work: We run Altiris/Deployment Solution and have to use auto-negotiate between client systems and our switches (Altiris apparently requires this for imaging, PXE boot and other functions). We have several areas with old wiring (Cat 3 & Cat 5) that have old 10/100 Cisco switches in them - and we can set these systems up to "auto/auto" (auto-negotiate on both the NIC and the switch port), and everything has been working fine. But - our networking crew changed out a couple of old switches for 10/100/1000 Cisco switches, and now - they are claiming that "auto/auto" won't work because the switches can't auto-negotiate the way the old 10/100 switches did - and that if we try to set the new gig switches to auto-negotiate, the switch port starts "port flapping", and shuts the port down. But - if we put the old switch back in - they work using "auto/auto" just fine - no port flapping. The networking crew is telling me that the problem is that we're putting "new switches" on "old wire", and that the old cabling can't/won't support the auto-negotiation with these new switches....??? There's something about this that doesn't make sense to me - can someone explain this to me? Or is our networking crew just doing something wrong in the configuration of these new switches? While will the old switches work "auto/auto", but the new switches won't?? HELP!!....and Thanks!! M

    Read the article

  • How do I get the IP address of a switch.

    - by Atilla Filiz
    I have a wireless AP+switch which I configured years ago, before moving, and haven't used for a while. Now I want to reconfigure it for my new network, but have no idea what I set as its IP address(It was probably something 192.168.xx.yy). What is the best way for discovering its IP? A script to spam the whole address space?

    Read the article

  • How do I quickly switch to/from the front panel speakers in Ubuntu?

    - by Jephir
    I have speakers attached to my front panel sound output that I switch to frequently. Currently the process is to open Terminal, type "alsamixer", scroll over to "Front Panel", and press "M" to activate it. Although this doesn't seem like much, it's a hassle when switching between outputs frequently. Are there any faster alternatives, such as a button that can be placed on the GNOME panel or a shortcut key that can be used?

    Read the article

  • Using Lan Management port - which kind of switch for remote control?

    - by zephyrus
    Hello everyone, I have no expertize in server hardware, however i have some IBM X3550 7978 and HP DL 160/G6 servers with 2 Lan ports, and a management port (that seem to be another Lan port). Have anyone tried to use the management to control remotely the low level functions of the servers (reboots for example) ? Which kind of switch or other devices have you used for this? thank you Massimiliano

    Read the article

  • Faster alternative to Python's SimpleHTTPServer

    - by Drew Noakes
    Python's SimpleHTTPServer is a great way of serve the contents of the current directory from the command line: python -m SimpleHTTPServer However, as far as web servers go, it's very slooooow... It behaves as though it's single threaded, and occasionally causes timeout errors when loading JavaScript AMD modules using RequireJS. It can take five to ten seconds to load a simple page with no images. What's a faster alternative that is just as convenient?

    Read the article

  • How to obtain argument not preceded by '-' or '--'

    - by Simone Margaritelli
    Hi guys, i have a program that needs command line arguments in the form : ./my_program -m256M -tm -t some_other_file The "some_other_file" argument is not bound to -t (-t it's just another functionality) so i can't take it as the optarg of any of the flags, neither can i assume it is the last argument in the list. How can i do this? Thanks

    Read the article

  • Parse multiple named command line parameters

    - by scholzr
    I need to add the ability to a program to accept multiple named parameters when opening the program via the command line. i.e. program.exe /param1=value /param2=value and then be able to utilize these parameters as variables in the program. I have found a couple of ways to accomplish pieces of this, but can't seem to figure out how to put it all together. I have been able to pass one named parameter and recover it using the code below, and while I could duplicate it for every possible named parameter, I know that can't be the preffered way to do this. Dim inputArgument As String = "/input=" Dim inputName As String = "" For Each s As String In My.Application.CommandLineArgs If s.ToLower.StartsWith(inputArgument) Then inputName = s.Remove(0, inputArgument.Length) End If Next Alternatively, I can get multiple unnamed parameters from the command line using My.Application.CommandLineArgs But this requires that the parameters all be passed in the same order/format each time. I need to be able to pass a random subset of parameters each time. Ultimately, what I would like to be able to do, is separate each argument and value, and load it into a multidimentional array for later use. I know that I could find a way to do this by separating the string at the "=" and stripping the "/", but as I am somewhat new to this, I wanted to see if there was a "preffered" way for dealing with multiple named parameters?

    Read the article

  • parsing the output of the 'w' command?

    - by Blackbinary
    I'm writing a program which requires knowledge of the current load on the system, and the activity of any users (it's a load balancer). This is a university assignment, and I am required to use the w command. I'm having a hard time parsing this command because it is very verbose. Any suggestions on what I can do would be appreciated. This is a small part of the program, and I am free to use whatever method i like. The most condensed version of w which still has the information I require is `w -u -s -f' which produces this: 10:13:43 up 9:57, 2 users, load average: 0.00, 0.00, 0.00 USER TTY IDLE WHAT fsm tty7 22:44m x-session-manager fsm pts/0 0.00s w -u -s -f So out of that, I am interested in the first number after load average and the smallest idle time (so i will need to parse them all). My background process will call w, so the fact that w is the lowest idle time will not matter (all i will see is the tty time). Do you have any ideas? Thanks (I am allowed to use alternative unix commands, like grep, if that helps).

    Read the article

< Previous Page | 27 28 29 30 31 32 33 34 35 36 37 38  | Next Page >