SRX

last person joined: yesterday 

Ask questions and share experiences about the SRX Series, vSRX, and cSRX.
  • 1.  Commit at command

    Posted 12-28-2012 21:58

    hi guys,

     

    i just have a small query.

     

    When you use "commit at" command and exit out and then when someone else does a "configure private" it shows below output

     

    root@junos1# quit 

    Exiting configuration mode

     

    root@junos1> configure private 

    warning: changes cannot be committed while 'configure exclusive' is active

    warning: uncommitted changes will be discarded on exit

    Entering configuration mode

    Users currently editing the configuration:

    root terminal d0 (pid 1492) on since 2012-12-29 04:35:50 UTC, idle 00:02:28

        commit-at

     

    [edit]

    root@junos1# 

     

    now how do i know what configuration was scheduled to be commited. I tried " sh | compare", " sh configuration | compare rollback 1" ,"sh system compare rollback 0 1 "etc but it doesn't show me the right info.  I can't make any changes now as if I want to commit them it  says as below.

     

    root@junos1# commit 

    error: Another commit is pending

     

     

    so how do i find out what configuration was scheduled to be commited by the other engineer. This is a lab environment but i would like to know .I know that i can clear his pending commit (if I am super user) and then do my changes and commit. But , I want to know the command to see what config changes were scheduled by the other user

     

    Please advise at your convienence

     

    Regards,



  • 2.  RE: Commit at command
    Best Answer

    Posted 12-29-2012 01:34


    You can view the configuration changes made if you login to "configure shared" mode
     
    primary:node0}[edit]
    root@SRX-100-1# delete snmp description SACHIN

    {primary:node0}[edit]
    root@SRX-100-1# run show system uptime
    node0:
    --------------------------------------------------------------------------
    Current time: 2012-10-11 12:16:20 UTC
    System booted: 2012-10-08 10:05:34 UTC (3d 02:10 ago)
    Protocols started: 2012-10-08 10:09:27 UTC (3d 02:06 ago)
    Last configured: 2012-10-10 05:35:49 UTC (1d 06:40 ago) by root
    12:16PM  up 3 days,  2:11, 1 user, load averages: 0.11, 0.10, 0.08

    node1:
    --------------------------------------------------------------------------
    Current time: 2012-10-11 12:16:15 UTC
    System booted: 2012-10-08 10:15:17 UTC (3d 02:00 ago)
    Last configured: 2012-10-10 05:35:38 UTC (1d 06:40 ago) by root
    12:16PM  up 3 days,  2:01, 1 user, load averages: 0.14, 0.13, 0.09

    {primary:node0}[edit]
    root@SRX-100-1# commit at 12:36:00
    node0:
    configuration check succeeds
    node1:
    configuration check succeeds
    commit at will be executed at 2012-10-11 12:36:00 UTC
    commit at will be executed at 2012-10-11 12:36:00 UTC
    Exiting configuration mode

    {primary:node0}
    root@SRX-100-1> configure shared
    Entering configuration mode
    Users currently editing the configuration:
      root terminal u0 (pid 8576) on since 2012-10-10 14:35:44 UTC, idle 21:41:38
          private [edit]
      root terminal u0 (pid 9144) on since 2012-10-11 12:15:21 UTC, idle 00:00:48
          commit-at

    {primary:node0}[edit]
    root@SRX-100-1# show | compare
    [edit]
    -  snmp {
    -      description SACHIN;
    -  }

    {primary:node0}[edit]
    root@SRX-100-1#

     

    Please mark as correct answer if that answers your question 🙂

     

    Regards,
    Sachin



  • 3.  RE: Commit at command

    Posted 12-29-2012 03:21

    hi sachin, thanks for your reply. you have definelty given me one way to checking it. I was trying to check this in my lab on Olive image running below version and couldnt find that option. perhaps i will find that on a real box 😉

     

    Model: olive
    JUNOS Base OS boot [12.1R1.9]

     

    root@junos1> configure ?
    Possible completions:
    <[Enter]> Execute this command
    batch Work in batch mode (commit happens in batch)
    dynamic Work in dynamic database
    exclusive Obtain exclusive lock (other users cannot make changes)
    private Work in private database (other's changes do not show)
    | Pipe through a command
    root@junos1> configure shared
    ^
    syntax error, expecting <command>.

    root@junos1> configure

     

    However,looks like it works even if I use just "confiigure" instead of  "configure shared". I was more interested in an operational command .

     

    Also , do you know how can I commit without clearing the other commit. As you can see from my first post , I cant commit unless the other commit is still pending. How do i get around this?

     

    root@junos1> configure
    Entering configuration mode
    Users currently editing the configuration:
    root terminal d0 (pid 1488) on since 2012-12-29 10:36:04 UTC, idle 00:05:17
    commit-at

    [edit]
    root@junos1# commit
    error: Another commit is pending

    [edit]
    root@junos1#

     

     



  • 4.  RE: Commit at command

    Posted 12-29-2012 04:06

    I just checked on real box

     

    [edit]
    root@SRX-Sof# set snmp description SACHIN

    [edit]
    root@SRX-Sof# show | compare
    [edit snmp]
    -  description "SRX 650 A";
    +  description SACHIN;

    [edit]
    root@SRX-Sof# commit at 23:23:23
    configuration check succeeds
    commit at will be executed at 2012-12-29 23:23:23 EET
    The configuration has been changed but not committed
    Exiting configuration mode

    root@SRX-Sof> configure shared
                            ^
    syntax error, expecting <command>.

    root@SRX-Sof> sonf
                  ^
    unknown command.
    root@SRX-Sof> configure private
    warning: changes cannot be committed while 'configure exclusive' is active
    warning: uncommitted changes will be discarded on exit
    Entering configuration mode
    Users currently editing the configuration:
      root terminal u0 (pid 1456) on since 2012-12-29 22:26:51 EET
          commit-at


    [edit]
    root@SRX-Sof#

    [edit]
    root@SRX-Sof# show | compare

    [edit]
    root@SRX-Sof# exit
    Exiting configuration mode

    root@SRX-Sof> configure exclusive
    error: configuration database locked by:
      root terminal u0 (pid 1456) on since 2012-12-29 22:26:51 EET, idle 00:00:36
          commit at

    root@SRX-Sof> configure
    Entering configuration mode
    Users currently editing the configuration:
      root terminal u0 (pid 1456) on since 2012-12-29 22:26:51 EET, idle 00:00:53
          commit-at
    The configuration has been changed but not committed

    [edit]
    root@SRX-Sof# commit
    error: Another commit is pending

    [edit]
    root@SRX-Sof#

     

    Perhaps "configure shared" works only on CLUSTER

     

    on a standalone box youshould not have any problems in viewing the config changes

     

    [edit]
    root@SRX-Sof# show | compare  <<<<<<<<<<<
    [edit snmp]
    -  description "SRX 650 A";
    +  description SACHIN;

    [edit]

    for your second question there is no way to commit without clearing the pending commit.