Need quick script

Our phone guy is going to be replacing all the digital phones in our building with IP phones. On occaision, we may need to change the configuration on a port (voice vlan and trunk ports allowed). Is their a script I can write that will allow hime to put in the three variable (IP of switch, port, and required vlan) and the script will connect to that switch and place the new config on the port? It would have to login with my TACACS credentials. Any suggestions?

Thank you for the quick reply. Smart ports look very cool. I like the idea and may find this useful for other purposes but if I am reading this right, it won't work for what I need. It looks like he would need to log into the switch to apply the macro. He is a phone guy and does not want to actually touch the switch. So I was looking for like a perl script of something that I could configure with my TACACS credentials. Also I won't know what port he needs reconfigured until he needs it, so I need him to be able to add the port number as a variable without him actually having to do any programming. he would be will to run it as part of a command (i.e run command.exe 10.10.10.22 g1/0/22 222, where 10.10.10.22 is switch IP, g1/0/22 is port, and 222 is the new vlan) or if I can do somekind of prompt that would be great!

Similar Messages

  • HELP, need quick script fix

    Hi,
    Our InDesign is acting up here. We are designing massive amounts of tables for various annual reports. After the design for print is done, these tables need exporting to xHTML.
    We have tested this extensively, and written complicated CSS files and many cell-styles to make it work.
    The thing is, that now when the final test-export needs to be done. InDesign suddenly returns a Stack Overrun error message when exporting. The only thing that seems to happen is that we cut out each page, paste it into a new document, save, and then do the xHTML export. But we are talking hundreds of pages here.
    My Apple script is not too good, but I am sure this can be done by a simple script. And I am quite sure it has been done before.
    Can anyone here please point me in the correct direction.
    PS. A bug report has been made to Adobe about this issue

    Thank you for the quick reply. Smart ports look very cool. I like the idea and may find this useful for other purposes but if I am reading this right, it won't work for what I need. It looks like he would need to log into the switch to apply the macro. He is a phone guy and does not want to actually touch the switch. So I was looking for like a perl script of something that I could configure with my TACACS credentials. Also I won't know what port he needs reconfigured until he needs it, so I need him to be able to add the port number as a variable without him actually having to do any programming. he would be will to run it as part of a command (i.e run command.exe 10.10.10.22 g1/0/22 222, where 10.10.10.22 is switch IP, g1/0/22 is port, and 222 is the new vlan) or if I can do somekind of prompt that would be great!

  • Need a script to create Log-Shipping status reports

    Hi All,
    In my company log shipping is set up for 5,6 databases i n each server so i need a script that which can generate reports at time for all the databases and i can get the mail about the reports. Is any T-Sql script av liable for this so i can check when ever
    the backup and restore files are update time of given latency.

    Hi,
    If you search online you get plenty of examples. I found below post interesting might help you as well.
    http://www.sqlservercentral.com/Forums/Topic1259335-391-1.aspx
    Please mark solved if I've answered your question, vote for it as helpful to help other users find a solution quicker
    Praveen Dsa | MCITP - Database Administrator 2008 |
    My Blog | My Page

  • Quick script question

    Hi all,
    Could anyone advise me if i can add anything within - header('Location: http://www.mysite.co.uk/thankyou.html'); in the script below so as the page
    re- directs back to the main index page after a few seconds ?
    Thankyou for any help.
    <?php
    $to = '[email protected]';
    $subject = 'Feedback form results';
    // prepare the message body
    $message = '' . $_POST['Name'] . "\n";
    $message .= '' . $_POST['E-mail'] . "\n";
    $message .= '' . $_POST['Phone'] . "\n";
    $message .= '' . $_POST['Message'];
    // send the email
    mail($to, $subject, $message, null, '');
    header('Location: http://www.mysite.co.uk/thankyou.html');
    ?>

    andy7719 wrote:
    Mr powers gave me that script so im rather confused at this point in time
    I don't think I "gave" you that script. I might have corrected a problem with it, but I certainly didn't write the original script.
    What you're using is far from perfect, but to suggest it would lay you open to MySQL injection attacks is ludicrous. For you to be prone to MySQL injection, you would need to be entering the data into a MySQL database, not sending it by email.
    There is a malicious attack known as email header injection, which is a serious problem with many PHP email processing scripts. However, to be prone to email header injection, you would need to use the fourth argument of mail() to insert form data into the email headers. Since your fourth argument is null, that danger doesn't exist.
    One thing that might be worth doing is checking that the email address doesn't contain a lot of illegal characters, because that's a common feature of header injection attacks. This is how I would tidy up your script:
    <?php
    $suspect = '/Content-Type:|Bcc:|Cc:/i';
    // send the message only if the E-mail field looks clean
    if (preg_match($suspect, $_POST['E-mail'])) {
      header('Location: http://www.example.com/sorry.html');
      exit;
    } else {
      $to = '[email protected]';
      $subject = 'Feedback form results';
      // prepare the message body
      $message = 'Name: ' . $_POST['Name'] . "\n";
      $message .= 'E-mail: ' . $_POST['E-mail'] . "\n";
      $message .= 'Phone: ' . $_POST['Phone'] . "\n";
      $message .= 'Message: ' . $_POST['Message'];
      // send the email
      mail($to, $subject, $message);
      header('Location: http://www.example.com/thankyou.html');
      exit;
    ?>
    Create a new page called sorry.html, with a message along the lines of "Sorry, there was an error sending your message". Don't put anything about illegal attacks. Just be neutral.
    By the way, when posting questions here, don't use meaningless subject lines, such as "Quick script question". If you're posting here, it's almost certain to be a question about a script. It doesn't matter whether it's quick. Use the subject line to tell people what it's about.

  • I'm trying to open the latest i-tunes but it keeps saying I need quick time 7.5 or higher

    I'm trying to open the latest i-tunes but it keeps saying I need quick time 7.5 or higher (which I do) and I have no updates available for quicktime

    QuickTime 7.5.5 for Leopard - http://support.apple.com/kb/DL27
    QuickTime 7.7 for Leopard - http://support.apple.com/kb/dl761
    = New version of Quicktime installed but application reports it needs to have that version installed =
    Open Application > Utilities > System Profiler and check the Quicktime version in Frameworks vs. the version in Applications.  One person had re-installed their operating system.  It had kept the newer Player application but had reverted to an earlier version of the underlying support framework files which many applications utilize.  Re-installing Quicktime 7.7 took care of the problem.  Do this manually, not with Software Update.
    Installation get stuck at "configuring installation" - https://discussions.apple.com/thread/2592979?threadID=2592979  - uninstall Quicktime before installing.

  • Why do I need Quick time 7 and Quicktime 10 ?

    I have just migrated from iMac5 (2.16 GHz) Mac OS 10.4.11 Quicktime 7.6.4 to a new imac 3.06 Mac OS 10.6.2 Quicktime 10.0.
    Some of my quicktime files play ok but others prompt me to download quicktime version 7. Why do I need to do this ? (There seem to be a lot of problems with this looking at the forums). All the files play on the old mac. Why isn't Quicktime forward compatible or why is there no import facility so that you can make your old files compatible ?
    Or am I missing something ?

    Some of my quicktime files play ok but others prompt me to download quicktime version 7. Why do I need to do this ?
    Because your system thinks you are missing specific codecs required for the playback of certain compression formats. In some cases this may be an installation problem in which the codec was "lost" or "orphaned" during the update process. In others it may be a need to update the component to work properly under the dual QT X/7 framework installed under the Snow Leopard OS. You need to check the Inspector/Finder Info or similar window to determine what specific codec is causing the problem and then re-install or update that specific codec/component/package.
    (There seem to be a lot of problems with this looking at the forums).
    Most of the problems are "self-inflicted" by individuals who, rather than studying the problem symptoms, analyzing them to determine their cause, and then fixing the problems, elect to immediately delete and re-install software -- often attempting to mix components from different operating systems and/or update versions of the software in their haste.
    All the files play on the old mac. Why isn't Quicktime forward compatible or why is there no import facility so that you can make your old files compatible?
    I am running both Leopard and Snow Leopard variations of QT v7.6.6 and all of my "old" files have remained compatible -- to include MPEG-2 video and a limited number of third-party supported compression formats. Since my configurations continue to work properly, my first guess is that you have an unresolved configuration problem or inability for your QT X 64-bit routines to communicate/switch properly with the 32-bit routines as required for your content.
    Why do I need Quick time 7 and Quicktime 10?
    Technically, you probably don't. However, as an old QT 7 Pro user who likes many of the QT 7 Player controls/options/features better than QT X's new but more basic features, I maintain both in active service and tend to use QT 7 as the default player of most of my work flows. Still, this is up to the individual. I am in no hurry to rush the changeover from an older but still more reliable QT technology to a more modern, but as yet, less mature and well tested "new" QT technology. In short, I feel it best to make the most of both dispensations during the development of this "new" version of QT.

  • I need a script, is it possible?

    Hello all,
         I need a script that does the following.
    I select an object in AI CS3 and then execute the script.
    1st. The script takes the object and fills it with 100% magenta and makes it a spot color named CC.
    2nd. The script then resizes the document to 1" larger than the selected object and centers all art in the middle of the art board,. (so if the object is 10.5" x 15.7" the document setup size is changed to 11.5" x 16.7")
    3rd. The script then stores the size of the selected object and the new resize of the document setup on the clipboard. So if I paste into notepad it would paste "10.5 X 15.7 - 11.5 X 16.7"
    That is it, it does not need to be exact on the pasting syntax but close if you know what I mean. This will be used in a production environment so a hot key to execute the script would be nice.
    If I can get help with this it would be awesome, Please let me know if you can help.
    Anton

    there you go
    var doc = app.activeDocument;
    var sel = doc.selection;
    var doc2 = null;
    for(j= sel.length - 1; j>= 0; j--) {
        var spotty = new SpotColor();
        spotty.tint = 100;
        var spottyColor = new CMYKColor();
        spottyColor.magenta = 100;
        spotty.spot = doc.spots.add();
        spotty.spot.colorType = ColorModel.SPOT;
        spotty.spot.name = "CC";
        spotty.spot.color = spottyColor;
        sel[j].fillColor = spotty;
        sel[j].name = "##REFERENCE";
        var nInc = new UnitValue(1, "in");
        var cWidth = new UnitValue(sel[j].width, "pt");   
        var cHeight = new UnitValue(sel[j].height, "pt");
        doc2 = app.documents.add(DocumentColorSpace.CMYK, cWidth + nInc.as("pt"), cHeight.value + nInc.as("pt"), 1);
        var newSel = sel[j].duplicate(doc2);
        var nTL = parseFloat((nInc.as("pt") / 2));
        var nTop = cHeight.value + nTL;
        newSel.position = [nTL, nTop];
        grabAndCenterObjects();
        var txtFrm = doc2.textFrames.add();
        txtFrm.contents = "Old dimensions: " + cWidth.as("in").toFixed(2) + " X " + cHeight.as("in").toFixed(2) + "\" New dimensions:" + (cWidth.as("in")+1).toFixed(2) + " X " + (cHeight.as("in")+1).toFixed(2) + "\"";
        doc2.selection = null;
        txtFrm.selected = true;
        app.copy();
        txtFrm.remove();
    function grabAndCenterObjects(ignorePath) {
        for(j = doc.pageItems.length - 1; j >= 0; j--) {
            if(doc.pageItems[j].name.indexOf("##REFERENCE") > -1) continue;
            var mElem = doc.pageItems[j].duplicate(doc2);
            var left = (doc.pageItems[j].width > doc2.width) ? -(doc.pageItems[j].width - doc2.width) / 2 : (doc2.width - doc.pageItems[j].width) / 2;
            var top = (doc.pageItems[j].height > doc2.height) ? (doc.pageItems[j].height + (doc.pageItems[j].height - doc2.height)/2) : (doc.pageItems[j].height + (doc2.height - doc.pageItems[j].height)/2);
            mElem.position = [left, top];
    hope it helps;
    cheers;

  • Need java script 6.26 to use banking software keep getting "the connection was reset" error Java appears on addon blocked list

    I am trying to use Team One Credit Unions CU@home to access my accounts. Their support team tells me I need Java script 6.26. I show that on my add on list but it also states Java is blocked on the blocked software list. How do I get Java script running so I can do my home banking or at least test it to be sure that is the issue. I have tried running this program with Java enabled and disabled with the same results.

    To avoid confusion: http://kb.mozillazine.org/JavaScript_is_not_Java
    See:
    * http://kb.mozillazine.org/Java
    * http://kb.mozillazine.org/JavaScript
    Java 6 U26 is about the Java plugin.
    You can see in "Tools > Add-ons > Plugins" if the Java plugin is installed and also on the about:plugins page via the location bar.
    * http://www.java.com/en/download/help/testvm.xml - How do I test whether Java is working on my computer? - 1.4.2_xx, 1.5.0, 6.0

  • HT4743 tv show will not play.  Says I need quick time

    Watched half of Bates motel epi and then it stops and says I need quick time.  I have a macbook air.  Makes no sense.
    Thanks.
    Dave

    Hi..
    Try the troubleshooting help here >  Troubleshooting iTunes for Windows Vista or Windows 7 video playback performance issues

  • I need quick time 7.5.5 for itunes.How to repair problem of installation?

    I have mac leopard 10.5.5 powerpc and I have itunes 10.6.3.
    Itunes need Quick Time 7.5.5 or more.
    I tried to install quick time but there is a problem of instalation.
    How to repair problem of installation of Quick Time?

    Some specific downloads of QuickTime:
    7.5.5 for Tiger
    7.6 for Tiger
    7.6.4 for Leopard
    7.7 for Leopard
    Since you have Mac OS X 10.5, Leopard, it would probably be better to use one of those Leopard-specific downloads.

  • Need help - need a script

    Hi All,
    I have no knowledge of applescript and need something made to meet a deadline. I am a graphic artist for the national office of a non-profit with 400 agencies.
    I need a script to control adobe illustrator to make customized logo packages for all of the agencies. I have 5 base documents. There are multiple logos per document. The text is set as "aaa" that needs to be customized. I am doing a find and replace to insert the text. Each file also has a 'tagline' layer that gets turned off and saved that way also.(a PNG) One master file gets saved as an illustrator PDF.
    I need the script to ask me what the agency number is and also what the agency name is and make/name a new folder and then process the logos in illustrator saving the files in the new folder.
    They needed to be completed yesterday, but it takes me roughly 10 to 15 minutes to do one agency. I have no time to work on them during the day a all so I am pretty deserate. We have no budget for this, but I am willing to pay $50 or so out of my own pocket(sorry... recently had twins so I'm broke too)
    Please contact me at [email protected] if you could do this.

    Hi jasonschaeffer
    try here
    http://macfreelancer.com/
    Budgie

  • I need a script to invert the page order of selected pages for cs5.

    Hello,
    I am a graphic designer and i am trying to create a easier way to make multiple page folders, By using the multiple page size feature in inDesign CS5. But my problem is that i can create the front side of the folder easier than before, the backside is my problem I need to inverse the page order manual, this creates a lot of mistakes and errors along the way. Thats why I need a script to invert the page order of the pages I select. I hope to hear from someone soon.
    My best regards,
    Gijs van Roij

    In /gateprd/ARCHIVE/*.arc
    This is the script to remove the archives after it has been backup by the netbackup policy named Archive. This policy removes the archives that have been backed up.
    /home/oracle/dba/scripts> more rmovarch.sh
    #!/bin/ksh
    # compress /gateprd/ARCHIVE/*.arc
    find /gateprd/ARCHIVE/*.arc -type f ! -exec echo {} > /home/oracl
    e/dba/lists/ARCHIVElist \;
    if test $(cat /home/oracle/dba/lists/ARCHIVElist|wc -l) -gt 0
    then
    echo "Hay archives. Se corre script de borrar"
    /home/oracle/dba/scripts/ARCHIVE_BACKUP.sh ARCHIVE
    else
    echo "No archives!!"
    fi

  • I need a script that copies the filename into the file

    I need a script that copies the filename into 4th column of each line in the text doc file.
    I have over 2000 different file names each containing 6 columns and ~50-100 rows.
    I can do this manually using this script:
    awk '{print $1"\t"$2"t\"$3"\t <name> \t"$6}'
    But I would like an automation command or script. Is there any command that I can use instead of <name> that will copy the filename into the column?
    Thanks
    Monica

    Oops, I forgot the redirect to a file. It's not a good idea to edit files in place. A script could fail and you're left with at least one file ruined. It's better to create new files then delete the old files.
    for file in *; do
        while read col1 col2 col3 col4 col5 col6; do              
            printf "%s\t%s\t%s\t%s\t%s\n" $col1 $col2 $col3 $file $col6
        done < $file > n$file
    done
    You could narrow the files listed such as
    for file in *.tsv
    and redirect the new files to another directory. Such as
    done < $file > /absolute/path/to/directory/$file

  • Need a script to move files to folders

    Hi guys.  I have found a lot of similar threads but not something exactly like what I need.
    I have a ton of files that need to be sorted into folders of the same name.  I found scripts to help me with that however, I have some variations on the files with an extension to the file name that also need to be moved into the same folders.
    For instance, I have a folder named....
    spiegal_case_25_video_3
    and I have the following files that all need to be moved into that folder....
    spiegal_case_25_video_3.mp4
    spiegal_case_25_video_3.webmsd.webm
    spiegal_case_25_video_3_h.flv
    spiegal_case_25_video_3_m.flv
    spiegal_case_25_video_3_l.flv
    I have found scripts to get me part of the way there but I can't get the FLVs into the folders because of the _h _m and _l extensions on the file names.  Is there a way to move these files into their appropriate folders (maybe by ignoring the last 2 characters in the file name?)
    I have also found a script that will read everything up to the underscore, but that won't help since the file names have multiple underscores.  So I really need a script that can do the sorting while ignoring the last 2 characters in the file name.
    Can anyone help me out?  I'm not very script savvy.
    Thanks!

    I've tested the following script (under OS X 10.8.5) with 4 subfolders and 20 files, all located in a folder called "Master folder" located in a USB flash drive named "EXT_DRIVE". It seems to work flawlessly. In its present state, the script will replace any file already located in any of the subfolders.
    set theMasterFolder to POSIX file "/Volumes/EXT_DRIVE/Master folder"
    tell application "Finder"
        activate
        set theFolders to (folders of folder theMasterFolder) as alias list
        repeat with thisFolder in theFolders
            set thisName to name of thisFolder
            move (files of folder theMasterFolder whose name begins with thisName) to thisFolder with replacing
        end repeat
    end tell

  • Need a script to enable in-place hold on Office 365

    Hello, I need a script to enable in-place hold on Office 365 for my users.
    The options that I have found for this so far is to enable in-place hold for a DL or an individual user. Is there a way to use a CSV instead?
    This is what I have used before.....where "allstaff" is the name of a DL.
    New-MailboxSearch -name "3 Year In-Place Hold" -SourceMailboxes allstaff -InPlaceHoldEnabled $true -ItemHoldPeriod 1095

    That doesn't seem to work.........I think it's trying to create a new hold query for every user.
    PS C:\scripts> ./user_hold.ps1
    WARNING: The hold setting may take up to 60 minutes to take effect.
    Name                CreatedBy           InPlaceHoldEnabled  Status
    3 Year In-Place ... S-1-5-21-2495351... True                NotStarted
    Unable to execute the task. Reason: A mailbox search named <3 Year In-Place Hol
    d> already exists or is currently being deleted. Please choose a different name
        + CategoryInfo          : InvalidArgument: (Microsoft.Excha...DiscoverySea
       rch:MailboxDiscoverySearch) [], MailboxSearchTaskException
        + FullyQualifiedErrorId : [Server=BLUPR06MB097,RequestId=e8df9b95-2e00-428
       d-813f-da05ea8d09d4,TimeStamp=11/5/2013 9:38:05 PM] [FailureCategory=Cmdle
      t-MailboxSearchTaskException] 95CD9ECA
    So my next question...........how do I add users to an existing In-Place hold?

Maybe you are looking for

  • On macbook pro photoshop is slow and not working.  In activity monitor I get switchboard nor responding

    photoshop bridge on my 3 year old mac pro has become inoperable.  In activity monitor is is using 180+ percent of CPU.  I also get switchboard not operating.  I deleted all of photoshop and bridge and reloaded them.  Same problem.  Does anyone know a

  • External hard drive choice

    Hi I would like to buy for a MBP an External Desktop Drive. This will be my first one. Could you please recommend me some good quality hard drive. Also could you please tell me when I am choosing what options to look for please? For example I would l

  • Accounting document entry date

    Is there a function to get the Accounting document entry date? Given the batch number (charg) and Number of material document (mblnr) Thanks.

  • Developer Suit 10g As Application Server

    Can i use 10g Developer Suit as my application server? i mean installing developer suit 10g and keeping oc4j running and report services running on my server machine serve the purpose of an application server? i have tried installing and configuring

  • Download and placing a remote pdf in an Illustrator Document.

    I'm trying to make an Illustrator that while download a pdf from a remote url and then allow the user place this on the page. I can download the pdf object no problem, but the PlacedItem needs a file handle. Is this possible or is it restricted due t