Is this the right way to configure WPA2 on 1131 AP?

Hello everyone.
I, at work, have recently deployed a very small stub network in Papua New Guinea, an office that has no more than 7/8 users.  This simple network consists of:
1 x 2611xm Router
1 x 2960 24port Catalyst Switch
1 x 1131ag AP
1 x Dell Server used for WSUS and Anti-Virus updates for users on the LAN.
NO VLANS - all connect to default vlan1
And that is it, no individual DNS/DHCP/Domain servers, or Radius/Authentication servers for that matter. 
Originally we deployed WEP on the AP, but today I configured WPA2.
That said, below is my AP config, and just looking for confirmation if its correct, or needs further improvement (remove any unnecessary commands)?
The switch has no additional VLANS configured, the link between the switch and the AP is NOT configured as trunk.
The router does not have additional sub-interfaces.  Simply put, fa0/0 goes to the public internet, fa0/1 goes to the inside switch.
Please note that wirless connectivity works OK, there are no issues, but i feel like i may have more unnecessary steps in my config than needed.
Thanks for your guidance and support.
Current configuration : 2583 bytes
version 12.4
no service pad
service timestamps debug datetime msec
service timestamps log datetime msec
service password-encryption
hostname WCS_GorokaAP
logging rate-limit console 9
enable secret 5 <removed>.
no aaa new-model
ip domain name <removed>
dot11 syslog
dot11 ssid wcs_goroka
   vlan 1
   authentication open
   authentication key-management wpa version 2
   mbssid guest-mode
   wpa-psk ascii 7 <wpa key>
bridge irb
interface Dot11Radio0
no ip address
no ip route-cache
encryption vlan 1 mode ciphers aes-ccm
ssid wcs_goroka
mbssid
channel 2437
station-role root
interface Dot11Radio0.1
encapsulation dot1Q 1 native
no ip route-cache
bridge-group 1
bridge-group 1 subscriber-loop-control
bridge-group 1 block-unknown-source
no bridge-group 1 source-learning
no bridge-group 1 unicast-flooding
bridge-group 1 spanning-disabled
interface Dot11Radio1
no ip address
no ip route-cache
encryption vlan 1 mode ciphers aes-ccm
ssid wcs_goroka
dfs band 3 block
mbssid
channel dfs
station-role root
interface Dot11Radio1.1
encapsulation dot1Q 1 native
no ip route-cache
bridge-group 1
bridge-group 1 subscriber-loop-control
bridge-group 1 block-unknown-source
no bridge-group 1 source-learning
no bridge-group 1 unicast-flooding
bridge-group 1 spanning-disabled
interface FastEthernet0
no ip address
no ip route-cache
duplex auto
speed auto
interface FastEthernet0.1
encapsulation dot1Q 1 native
no ip route-cache
bridge-group 1
no bridge-group 1 source-learning
bridge-group 1 spanning-disabled
interface BVI1
ip address 192.168.15.241 255.255.255.0
no ip route-cache
ip default-gateway 192.168.15.254
ip http server
no ip http secure-server
ip http help-path http://www.cisco.com/warp/public/779/smbiz/prodconfig/help/eag
bridge 1 route ip
banner motd ^C
* This is a secured Access Point.  Unauthorized logins are strictly restricted. *
^C
line con 0
password 7 <console password>
logging synchronous
login
line vty 0 4
exec-timeout 30 0
password 7 <telnet password>
logging synchronous
login
transport input telnet
line vty 5 15
login
end

thats correct.
keep this link as reference:
http://www.cisco.com/en/US/partner/tech/tk722/tk809/technologies_configuration_example09186a008054339e.shtml
http://www.cisco.com/en/US/partner/products/hw/wireless/ps4570/products_configuration_example09186a00801c40b6.shtml
Please make sure to rate correct answers

Similar Messages

  • Hi! I´m having problems with showing video files in Qlab on my Macbook Air. A sound/video technician told me to "blow out" my Mac. Was told to use  cmd+ r  when restarting. Is this the right way?

    Hi! I´m having problems with showing video files in Qlab on my Macbook Air. It started suddenly. Consulted a sound/video technician who told me to "blow out" my Mac. Was told to use cmd+r  when restarting. Is this the right way to clean up my Mac? And is it likely that some kind of bug is causing problems for Qlab to show video files? I´ve already tried with a bunch of different video files and sometimes Qlab plays them and sometimes not. I need the Qlab playlist for a theatre show and only have a week until showtime so starting to really worry. Is there anyone out there who can help?

    Your Mac runs maintenance in the background for you.
    Command + R gives you access to restore, repair, or reformat the drive using OS X Recovery
    No idea why that was suggested.
    You may have a third party video player installed that's causing an incompatibility issue.
    Check these folders:
    /Library/Internet Plug-Ins/
    /Library/Input Methods/
    /Library/InputManagers/
    /Library/ScriptingAdditions
    ~/Library/Internet Plug-Ins/
    ~/Library/Input Methods/
    ~/Library/InputManagers/
    ~/Library/ScriptingAdditions
    The first four locations listed are in the root-level Library on your hard disk, not the user-level Library in your Home folder.The tilde (~) represents your Home folder.
    To access the Home folder in OS X Lion or Mountain Lion, open the Finder, hold the Option key, and chooseGo > Library.

  • Thread safety! Is this the right way?

    Hello,
    Lately I'm reading lot about thread-safety in Swing...
    so just wondering that is this the right way to code ...
    For ex following code executes(which makes DB connection and load some list) when user press the "connect (JButton)" ....
    private void prepareAndShowConnBox()
            //System.out.println("prep - EDT: " + javax.swing.SwingUtilities.isEventDispatchThread());
            pwd.setEchoChar('*');
            javax.swing.Box box1 = new javax.swing.Box(javax.swing.BoxLayout.Y_AXIS);
            javax.swing.Box box2 = new javax.swing.Box(javax.swing.BoxLayout.Y_AXIS);
            box1.add(new javax.swing.JLabel("DB URL :     "));
            box2.add(db_url);
            box1.add(new javax.swing.JLabel("User Name :  "));
            box2.add(uid);
            box1.add(new javax.swing.JLabel("Password :   "));
            box2.add(pwd);
            final javax.swing.Box box = new javax.swing.Box(javax.swing.BoxLayout.X_AXIS);
            box.add(box1);
            box.add(box2);
            int retval = javax.swing.JOptionPane.showOptionDialog(me, box,
                    "Database Connection:",
                    javax.swing.JOptionPane.OK_CANCEL_OPTION,
                    javax.swing.JOptionPane.QUESTION_MESSAGE,
                    null, null, null);
            if(retval == javax.swing.JOptionPane.OK_OPTION)
                status.setText("Connecting...");
                Thread t = new Thread(makeConn, "Conn Thread");
                t.setPriority(Thread.NORM_PRIORITY);
                t.start();
        }And the makeConn is....
    private Runnable makeConn = new Runnable()
            boolean success;
            Exception x;
            public void run()
                //System.out.println("Con - EDT: " + javax.swing.SwingUtilities.isEventDispatchThread());
                success = true;
                x = null;
                try
                    //load sun JDBC-ODBC bridgr driver...
                    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
                    //make connection to DB...
                    con = java.sql.DriverManager.getConnection("jdbc:odbc:" + db_url.getText(),
                            uid.getText(), new String(pwd.getPassword()));
                catch(Exception e)
                    success = false;
                    x = e;
                    System.err.println(x);
                java.awt.EventQueue.invokeLater(GUItask);
            Runnable GUItask = new Runnable()
                public void run()
                    //System.out.println("Con gui - EDT: " + javax.swing.SwingUtilities.isEventDispatchThread());
                    if(success)
                        bConn.setText("Disconnect");
                        status.setText("");
                        status.setIcon(imgLink);
                        imgLink.setImageObserver(status);
                        //load the pic list...
                        Thread t = new Thread(execQuery, "List1 Thread");
                        t.setPriority(Thread.NORM_PRIORITY);
                        t.start();
                    else
                        status.setText("Connection Failed.");
                        showErr(x.toString());
        };Here uid,db_url (JTextField) , pwd (JPasswordField) , status (JLabel) are class fields.
    Thanks for any comments... :)

    Threading looks fine too me... the connection is created on a background thread, but (critically) all GUI updates are performed on the EDT, even if there's an exception. Well done.
    My only comment is... why is your GUI creating a database connection at all? Ideally the controler would get the DAO (which would connect itself) and inject it (the connected DAO) into the view... but I'm a server-side boy, so feel free to ignore me.
    Cheers. Keith.

  • Is this the right way - 9i

    I have schema 'A' with few large and many small non-partition tables. I created another schema 'B' identical to 'A' and the only difference was that I partitioned the large tables resulting a combination of partitioned and non partitioned tables in schema 'B'.
    I exported schema 'A' and imported it into 'B'. My question is, IS this the right way or I should done something else.
    Thx

    It would depend on the your goals, but I'd suspect that you would want to create most of the same indexes and views in the new schema. If you're partitioning the tables, though, you would have to give serious thought to how to define the indexes-- should they be global or local, should they be equipartitioned with the underlying tables, etc.-- which exporting and importing wouldn't resolve.
    If the end goal of this exercise is just to produce the same schema with partitioned tables, transition any code & applications to the partitioned schema, and then drop the unpartitioned schema, creating the new schema just adds extra work. Create partitioned tables in the same schema (with slightly different names), load the data, create appropriate indexes, and then ALTER TABLE ... RENAME everything so that the partitioned tables now have the old non-partitioned table names.
    Justin

  • Being Nice to your Layout manager - Is this the right way?

    Ive written a custom component that basically provides multi-line text wrapping and a few other nice things.
    I had a bit of trouble when I came to implementing
    getPreferredSize()  getMinimumSize() This is because ideally, I'd like the component to use as much space horizontally as possible, whilst using only as much vertical space as necessary.
    To do this, I used the parents width as the minimum horizontal size. This then allowed me to work out the height.
    Question is - is that the right way to do it? Other than that, I just cant think of a way to get the width I need when the component is first added to its container.
    Cheers for any input,
    Dave

    If you want it to use as much horizontal space as possible, that means you want its width to be equal to its container's width (perhaps minus a bit for borders or something). So in that case you would have to set its minimum width to that number, and that's exactly what you did. There could be other ways to do it, but yours seems perfectly fine to me.

  • Is this the right way of using Enhancement spots?

    Hi fellow SDN people.
    We are implementing some changes to standard SAP IDOC:s using the new enhancement technique and I just wanted to check with you guys about our approach. Please look at the code below and comment on our solution. Is there a better way of doing this in general? Are we using the BAdI concept wrong?
    ENHANCEMENT 32  Z_IDOC_INPUT_STPPOD.    "active version
    * Data declarations
    DATA:
      con    TYPE REF TO zcl_ex__badi_input_stppod1,
      handle TYPE REF TO z_badi_input_stppod1,
      l_oref TYPE REF TO cx_root,
      e_text TYPE string.
    * Instantiate objects
    CREATE OBJECT con.
    GET BADI handle CONTEXT con.
    TRY.
    *   Call BAdI
        CALL BADI handle->create_pod
          CHANGING
            processing_protocol = t_prox[]
            idoc_contrl         = idoc_contrl
            idoc_data           = idoc_data[].
      CATCH cx_badi_not_implemented INTO l_oref.
        e_text = l_oref->get_text( ).
        MESSAGE e_text TYPE 'E'.
    ENDTRY.
    APPEND LINES OF t_prox TO t_prot.
    LOOP AT t_prot.
      IF t_prot-msgty = 'E'.
        f_stat = 2.
        EXIT.
      ENDIF.
      IF t_prot-msgty = 'W' OR
         t_prot-msgty = 'I'.
        f_stat = 1.
      ENDIF.
    ENDLOOP.
    ENDENHANCEMENT.
    <i></i>

    Hi nirre,
    That's right.....
    In general the thumb rule for this is:"
    The enhancement implementation should be complete, let me clear with this example:
    data:
    begin of xy_12_12,
    x12 type i,
    y12(2) type c,
    end of xy_12_12.
    now if i want to enhance the code via implementing the implicit enhancement spot, that implementation should be complete in itself.i.e
    begin of xy_12_12,
    x12 type i,
    y12(2) type c,
    >>
    data : e12 type i.
    <<<
    end of xy_12_12.
    Hope it will clear the concept.
    regrads,
    Amit

  • Implicit Fact Column - am I thinking about this the right way?

    My exploration of the Implicit Fact Column is below. Let me know if you think this is the intended usage.
    When the BI Server sees a request where one Dimension is being constrained by another, it has to pick a fact table that contains references to these two dimensions. The "Implicit Fact Column", which is set in the Presentation Layer of the RPD is used to guide the BI Server towards one or more Fact tables that can be used to satisfy the request. In the absence of the Implicit Fact Column, I noticed that the BI Server was choosing random fact tables so I went exploring how this feature worked. I set the Implicit Fact column in my Presentation layer and then went looking to see how the queries were generated.
    For my example, my two dimensions are Program and Channel. I want to see the list of Channels available for a Program. Without the Implicit Fact Column, the queries are of the form:
    select distinct T289.CHANNEL_NAME as c1,
    T36001.PROGRAM_NAME as c2
    from
    DIM_PROGRAMS T36001,
    DIM_CHANNELS T289,
    SomeRandomFactTable T41210
    where ( T289.DIM_CHANNEL_KEY = T41210.DIM_CHANNEL_KEY and T36001.DIM_PROGRAM_KEY = T41210.DIM_PROGRAM_KEY )
    order by c1, c2
    The nice part about this is that there is only one set of Program / Channel combinations returned. The downside is that the Fact table that is chosen to resolve the combinations can be any Fact table under the purview of the BI Server. It doesn't even have to be in the same subject area where the Program and Channel were chosen. When I set the Implicit Fact Column, the queries are of the form:
    select distinct T289.CHANNEL_NAME as c1,
    T36001.PROGRAM_NAME as c2,
    T35832.DIM_SITE_KEY /* this is the implicit fact column */
    from
    DIM_PROGRAMS T36001,
    DIM_CHANNELS T289,
    AFactTableMappedToFactColumn T35832
    where ( T289.DIM_CHANNEL_KEY = T35832.DIM_CHANNEL_KEY and T35832.DIM_PROGRAM_KEY = T36001.DIM_PROGRAM_KEY )
    order by c1, c2
    I was happy that I could predict what Fact table was being used, but now the results are wrong as I get a duplicate set of records for every DIM_SITE_KEY / Channel / Program combination. I decided to play a little Algebra trick. Knowing that the DIM_SITE_KEY was a numeric value, I defined the Implicit fact column as DIM_SITE_KEY / DIM_SITE_KEY which will always result in a value of 1. Now I get queries that look like:
    select distinct T289.CHANNEL_NAME as c1,
    T36001.PROGRAM_NAME as c2,
    T35832.DIM_SITE_KEY / nullif( T35832.DIM_SITE_KEY, 0) as c3
    from
    DIM_PROGRAMS T36001,
    DIM_CHANNELS T289,
    AFactTableMappedToFactColumn T35832
    where ( T289.DIM_CHANNEL_KEY = T35832.DIM_CHANNEL_KEY and T35832.DIM_PROGRAM_KEY = T36001.DIM_PROGRAM_KEY )
    order by c1, c2
    Since DIM_SITE_KEY / DIM_SITE_KEY is always equal to 1, I only get one set of Program / Channel combinations. I get the added bonus of knowing which set of Fact tables are going to be used to satisfy the request.

    Perfect Analysis, But one important note is when using implicit fact table, Always select measure( Which has some aggregation) as a implicit fact column. So that will allows the query will eliminate duplicate rows by doing a group by operation.
    Other note is make sure performance is good. When we don't have a good model for fact tables, when the tables contains large set of data, make sure performance is good by doing indexes or caching to load the prompts.
    - Madan

  • Is this the right way to implement a database using SQL Server Express?

    Purchase a single central server (if you don’t have one already) and house it in the Wild Wood Apartments headquarters located in San Francisco, California
    Purchase and install Windows Server 2012 Datacenter onto this single central server.
    Along with the Windows Server 2012 Datacenter, you will have to purchase a license called Client Access License or commonly referred to as CAL
    Install SQL Server Express onto this single central server as well
    You will then need to install remote desktop access to each computer in the 20 building complexes Wild Wood Apartments owns. This allows each complex manager to access SQL Server Express on their computer and input information into the database.
    Is there anything that I would have to add on or include, am I missing something, or is something incorrect?
    Thank you

     This allows each complex manager to access SQL Server Express on their computer and input information into the database.
    Yes, but application software must be developed or purchased.
    Your design would work for a small scale database and application. More likely you need a pay SS product such as Standard Edition.
    Kalman Toth Database & OLAP Architect
    SQL Server 2014 Database Design
    New Book / Kindle: Beginner Database Design & SQL Programming Using Microsoft SQL Server 2014

  • Is this the right way to use Methods on Table - Get Procedure

    Hello,
    I just would like to make sure that the following is the use for which
    we use Get Procedure in Table API Package. ? And are there other use cases ?
    If we create a package on EMP Table, we get few Procedure .eg : Insert , Update, GET
    We use Get procedure when having few forms on different Tables on one page
    to manually fetch the values instead of using Automatic Row Processing (DML) .
    In PL/SQL process - On Load After Header. this code goes :
    BEGIN
    EMP_PKG.GET_EMP (
    :P3_EMPNO,
    :P3_ENAME,
    :P3_JOB,
    :P3_MGR,
    :P3_HIREDATE,
    :P3_SAL,
    :P3_COMM,
    :P3_DEPTNO
    DEPT_PKG.GET_DEPT ( .......
    END;And the Source Used Attribute of the items is:
    Only when Current value in Session State is Null.
    Regard,
    Fateh

    Fateh wrote:
    Thanks,
    Actually, I got the idea when skimming PL/SQL best practice book. I agree with with Steven Feuerstein on most of his PL/SQL best practices, but not on the use of TAPIs.
    There was a cancelled webinar by Dan - Taking Control: Integrating PL/SQL APIs with APEX.
    http://www.danielmcghan.us/2013/03/webinar-tomorrow-taking-control.html
    The abstract doesn't specifically mention TAPIs, but if that's the approach he was going to present then I'd disagree with it.
    Which PL/SQL APIs You mean ?Packages as described by Tom Kyte in the links above.

  • Is this this the right way to join them?

    i have 3 tables basically liked
    create table Sales_person
    SalesPersonID
    TransactionID
    create table Customer_Sales
    CustomerID
    TranactionID
    create table Sales
    TransactionID
    SoldDate
    SalesItemID
    SoldAmount
    SoldQuanity
    If I want a resulting table that show all the sales, sales person, and customer
    SalesPersonID
    CustomerID
    TransactionID
    SoldDate
    SalesItemID
    SoldAmount
    SoldQuanity
    would a sql statement like the following work?
    select *
    from sales s
    LEFT join Customer_sales cs
    on s.transactionID=cs.transactionID
    LEFT join Sales_person sp
    on sp.transactionID=s.transactionID
    how is it different than
    select *
    from sales s
    INNER join Customer_sales cs
    on s.transactionID=cs.transactionID
    INNERjoin Sales_person sp
    on sp.transactionID=s.transactionID

    Both versions will "work", that is, they are syntactically correct, but it depends on what you really mean by work. The two queries are asking different questions and whehter either, both, or neither are correct depends on the the data in the tables. Your first query is an outer join, while the second is an inner join.
    What the first query says is give me all of the rows in the sales table, and if there is a matching row in customer_sales give me the customer_sales information, otherwise make up a row with null in all columns, similarly for the sales_person table, if there is a match, give me the data otherwise make up a row.
    The second query says give me all of the rows from the sales table where there is a matching record in both the customer_sales table and the sales_person table. If either join fails, then that sale will not be returned by the second query.
    So, if it is possible that a sale could be made to a "non-customer" (i.e. no row in the customer_sales table), or not made by a sales person (i.e. no row in sales_person table), then the two queries are different.
    Consider this simplified data set against your first query:
    SQL> WITH
      2     sales_person AS (
      3        SELECT 1 salespersonid, 100 transactionid FROM dual UNION ALL
      4        SELECT 1, 101 FROM dual UNION ALL
      5        SELECT 2, 102 FROM dual),
      6     customer_sales AS (
      7        SELECT 10 customerid, 100 transactionid FROM dual UNION ALL
      8        SELECT 11, 101 FROM dual UNION ALL
      9        SELECT 12, 102 FROM dual),
    10     sales AS (
    11        SELECT 100 transactionid, 10 soldamount FROM dual UNION ALL
    12        SELECT 101, 25 FROM dual UNION ALL
    13        SELECT 102, 30 FROM dual UNION ALL
    14        SELECT 105, 50 FROM dual)
    15  SELECT *
    16  FROM sales s
    17     LEFT JOIN customer_sales cs
    18        ON s.transactionid = cs.transactionid
    19     LEFT JOIN sales_person sp
    20        ON s.transactionid = sp.transactionid;
    TRANSACTIONID SOLDAMOUNT CUSTOMERID TRANSACTIONID SALESPERSONID TRANSACTIONID
              100         10         10           100             1           100
              101         25         11           101             1           101
              102         30         12           102             2           102
              105         50and against you second query:
    SQL> WITH
      2     sales_person AS (
      3        SELECT 1 salespersonid, 100 transactionid FROM dual UNION ALL
      4        SELECT 1, 101 FROM dual UNION ALL
      5        SELECT 2, 102 FROM dual),
      6     customer_sales AS (
      7        SELECT 10 customerid, 100 transactionid FROM dual UNION ALL
      8        SELECT 11, 101 FROM dual UNION ALL
      9        SELECT 12, 102 FROM dual),
    10     sales AS (
    11        SELECT 100 transactionid, 10 soldamount FROM dual UNION ALL
    12        SELECT 101, 25 FROM dual UNION ALL
    13        SELECT 102, 30 FROM dual UNION ALL
    14        SELECT 105, 50 FROM dual)
    15  SELECT *
    16  FROM sales s
    17     JOIN customer_sales cs
    18        ON s.transactionid = cs.transactionid
    19     JOIN sales_person sp
    20        ON s.transactionid = sp.transactionid;
    TRANSACTIONID SOLDAMOUNT CUSTOMERID TRANSACTIONID SALESPERSONID TRANSACTIONID
              100         10         10           100             1           100
              101         25         11           101             1           101
              102         30         12           102             2           102John

  • UPDATED: Is this the right way to do it?

    I want to create an adress book..this is what I have...is this good?
    import apcslib.*;
    import chn.util.*;
    import java.util.* ;
    import java.io.*;
    public class Address
    FileOutput outFile = new FileOutput("database.txt");
    ConsoleIO k = new ConsoleIO();
    // Sets up this Address object with the specified data.
    public Address()
    System.out.print("Profile: ");
    String filename = k.readLine();
    System.out.print("Name: ");
    String name = k.readLine();
    System.out.print("Street: ");
    String street = k.readLine();
    System.out.print("City: ");
    String town = k.readLine();
    System.out.print("State: ");
    String st = k.readLine();
    System.out.print("Zip: ");
    int zip = k.readInt();
    FileOutput outFile = new FileOutput(filename+".txt");
    outFile.println(name);
    outFile.println(street);
    outFile.println(town);
    outFile.println(st);
    outFile.println(zip);
    outFile.close();
    // Returns this Address object as a string.
    public static void main(String[] args)
    ConsoleIO k = new ConsoleIO();
    String ans2= "";
    ArrayList address = new ArrayList();
    do
    System.out.print("1. New Account\n2. Existing Account\n3. View account\n4. Exit\n");
    String ans = k.readToken();
    if (ans.equals("1"))
    Address P = new Address();
    address.add(P);
    else if (ans.equals("2"))
    String peoplename,streetAddress, city, state;
    int zipCode;
    System.out.print("\nProfile name: ");
    String file = k.readLine();
    FileInput inFile = new FileInput(file+".txt");
    System.out.println("Name: " + inFile.readLine());
    System.out.println("Address: " + inFile.readLine());
    System.out.println("City: " + inFile.readLine());
    System.out.println("State: " + inFile.readLine());
    System.out.println("Zip: " + inFile.readLine());
    inFile.close();
    System.out.println();
    System.out.print("Name: ");
    String name = k.readLine();
    System.out.print("Street: ");
    String street = k.readLine();
    System.out.print("City: ");
    String town = k.readLine();
    System.out.print("State: ");
    String st = k.readLine();
    System.out.print("Zip: ");
    int zip = k.readInt();
    FileOutput outFile = new FileOutput(file+".txt");
    outFile.println(name);
    outFile.println(street);
    outFile.println(town);
    outFile.println(st);
    outFile.println(zip);
    outFile.close();
    else if (ans.equals("3"))
    System.out.print("\nProfile name: ");
    String file = k.readLine();
    FileInput inFile = new FileInput(file+".txt");
    System.out.println("Name: " + inFile.readLine());
    System.out.println("Address: " + inFile.readLine());
    System.out.println("City: " + inFile.readLine());
    System.out.println("State: " + inFile.readLine());
    System.out.println("Zip: " + inFile.readLine());
    System.out.print("Do you want to exit? ");
    System.out.println();
    ans2 = k.readToken();
    }while (ans2.equalsIgnoreCase("n"));
    }

    Just browsing through this code I see this constructor:
    public class Address
    FileOutput outFile = new FileOutput("database.txt");
    ConsoleIO k = new ConsoleIO(); And then in main (also in the same public scope):
    public static void main(String[] args)
    ConsoleIO k = new ConsoleIO();

  • HT201317 I can't upload my videos from my ipone 4s to my comuter, i apprecaite if anybody can help me  with this...someone said use safari or drop box..is this the right way to go about it?

    i Can't upload my videos from my iphone 4s to my computer, what software should i use to do this?

    As far as I know you can't delete the primary email address for an iCloud account.  It's assigned when the account is created.  But your neighbor wouldn't have been able to get into your iCloud account without your Apple ID and password.  Are you sure the account wasn't still on your phone when you gave it to him?
    You could migrate a copy of your data to a new iCloud account but I would still be concerned that someone else was using my old account, which presumably still has your data in it.
    I'm fairly certain that you're going to have to have iCloud support help you sort this one out as they may have the ability to make changes to an existing account that users can't.  Make an appointment with the genius bar at a nearby Apple store and have them take a look at it.  If necessary, they should be able to contact iCloud support for you.

  • Am I going about this the right way?

    Hello,
    I will place the code below. I have a JTextArea that I want to read the input of my process out to. I start a process which is just a shell script from the gui using the run button and I want to get what the script is outputting, onto the screen in my JTextArea. Any Ideas would be greatly appreciated. Thanks.
    import javax.swing.*;
    import java.awt.event.*;
    import java.io.*;
    import java.awt.*;
    //Sets up gui with run and cancel button, and text field for the I.P//
    public class OrderVodScript extends javax.swing.JFrame implements ActionListener {
        JTextField enterIp = new JTextField(16);
        JButton run = new JButton("Run");
        JButton cancel = new JButton("Cancel");
        public OrderVodScript() {
            super("Order VOD Script");
            setSize(900, 500);
            setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
            JPanel pane = new JPanel();
            JLabel enterIpLabel = new JLabel("Enter I.P Address or Full Path To A File Of I.P Addresses: ");
            pane.add(enterIpLabel);
            pane.add(enterIp);
            pane.add(run);
            pane.add(cancel);
            cancel.addActionListener(this);
            run.addActionListener(this);
            JPanel textPane = new JPanel();
            JTextArea text = new JTextArea(20,70);
            JScrollPane scrollPane = new JScrollPane(text);
            //Put them together
            FlowLayout flow = new FlowLayout();
            setLayout(flow);
            add(pane);
            add(scrollPane);
            setVisible(true);
        //Method to tell which button was pressed//
    public void actionPerformed(ActionEvent evt) {
        Object source = evt.getSource();
        if (source == cancel) {
          System.exit(0);
      } else if (source == run) {
          String ip = enterIp.getText();
         try {
              Process child = new ProcessBuilder("testvodscript" +ip).start();
              BufferedReader input = new BufferedReader(new
              InputStreamReader(child.getInputStream()));
              input.readline(text);
       }  catch (IOException e) {
                        e.printStackTrace();
       public static void main(String[] arguments) {
       OrderVodScript order = new OrderVodScript();
    }

    close...
    String NL = System.getProperty("line.separator");
    String line = "";
    BufferedReader input = new BufferedReader(new
              InputStreamReader(child.getInputStream()));
    while((line = input.readline()) != null) {
       text.append(line + NL);
    }

  • Right way to configure Tomcat JDBC resource for MaxDB

    Hi,
    i need to configure one tomcat server with a pool of connections for a MaxDB instance with follow database parameters:
    MAXUSERTASKS=150
    SESSION_TIMEOUT=60
    i do this configuration on tomcat:
    <Resource name="jdbc/myApp"
                    auth="Container"
                    type="javax.sql.DataSource"
                    username="DBUSER"
                    password="secret"
                    driverClassName="com.sap.dbtech.jdbc.DriverSapDB"
                    url="jdbc:sapdb://dbserver/DBNAME"
                    maxActive="150"
                    maxIdle="75"
                    validationQuery="SELECT NOW() FROM DBA.DUAL"/>
    is this the right way? there is a way to check if the pool is working at database side? at java side i checked that the javax.sql.DataSource.loginTimeout is Unavailable, then what is the better way to avoid errors like:
    2008-06-02 13:54:36  2165 WNG 11824 COMMUNIC Releasing  T187 command timeout
    i think that this problem occurs because the SESSION_TIMEOUT is 60, and the loginTimeout is Unavailable at javax.sql.DataSource then the DBCP of tomcat dont know when need to revalidate the session.
    thanks for any help.
    Clóvis

    Hi Clovis,
    to be honest, I'm no Tomcat expert at all. All I can do is read the documentation.
    The error message you posted was about an timeout due to a too long idle session.
    From the changes in your connection pool setup I cannot see any parameter that would influence this.
    Instead - as already written - you may either want to change the session timeout in general, for the user or (by adding some connection parameters) for the sessions.
    Concerning the question on wether it's better to have many connections or just a few - well this depends on what the java tasks do with the sessions.
    The connection pool is used for saving resources on the database side and the time necessary to logon and create a session.
    So whenever any of the java tasks needs a db connections it should "just get one" from the pool.
    When you have "high load" (by the way what exactly does that mean? High CPU usage on the J2EE server? Huge transaction volume? Many parallel transactions?) this does not change.
    Anyhow you have to be aware of the fact that the database can only process as many SQL requests in parallel as there are user kernel threads (UKTs) and each of the UKTs need to be able to run on a seperate CPU core. Therefore if it's necessary to have real parallel SQL activity many connections may not be the best idea.
    On the other hand this requirement is seldom necessary - most often sessions can wait a bit until they get the reply from the database and synchronize on each other later on. At least that's how we do it with NetWeaver.
    KR Lars

  • How to approach ABAP OO programming the right way...

    Hello experts,
    I am an old school procedural ABAP programmer and I recently I have been experementing with ABAP Objects since I've read a few columns the advantages of ABAP OO and also currently learning its syntax. Now, does ABAP Objects conform to the old way of say, doing reports like at selection-screen output, at selection-screen, on value-request for..., start-of-selection, end-of-selection, top-of-page, etc. I have been doing some practice programs and I am not sure if my approach is correct. Example, I created a class named cl1 and I have a method named upload. Now, the UPLOAD method contains the function 'GUI_UPLOAD'. Is this the right way of doing it? Also, How come I cannot create structures inside a class?
    Again, thanks guys and have a nice day!

    Hi,
    I have these three progs from one of the previous posts.
    Good approach on using constructors. I am not finding the original link.
    *& Report ZABAP_OBJ_01 *
    REPORT zabap_obj_01 .
    PARAMETERS : p_vbeln LIKE vbap-vbeln OBLIGATORY,
                 p_matnr LIKE mara-matnr.
    TYPES : BEGIN OF ty_vbap,
    vbeln TYPE vbap-vbeln,
    matnr TYPE vbap-matnr,
    arktx TYPE vbap-arktx,
    END OF ty_vbap.
    * CLASS sales_order DEFINITION
    CLASS sales_order DEFINITION.
      PUBLIC SECTION.
        DATA : v_matnr TYPE mara-matnr,
        v_vbeln TYPE vbap-vbeln.
        METHODS : constructor IMPORTING vbeln TYPE vbap-vbeln
        matnr TYPE mara-matnr OPTIONAL.
        DATA : it_vbap TYPE STANDARD TABLE OF ty_vbap.
        METHODS : get_vbap_details,
        disp_vbap_details.
    ENDCLASS. "sales_order DEFINITION
    * CLASS sales_order IMPLEMENTATION
    CLASS sales_order IMPLEMENTATION.
      METHOD get_vbap_details.
        CLEAR : it_vbap.
        REFRESH : it_vbap.
        SELECT vbeln
        matnr
        arktx
        FROM vbap
        INTO TABLE it_vbap
        WHERE vbeln = p_vbeln.
      ENDMETHOD. "get_vbap_details
      METHOD constructor.
        CLEAR : v_vbeln,
        v_matnr.
        v_vbeln = vbeln.
        v_matnr = matnr.
      ENDMETHOD. "constructor
      METHOD disp_vbap_details.
        DATA : wx_vbap LIKE LINE OF it_vbap.
        LOOP AT it_vbap INTO wx_vbap.
          WRITE :/ wx_vbap-vbeln,
          wx_vbap-matnr,
          wx_vbap-arktx.
        ENDLOOP.
        CLEAR : it_vbap.
      ENDMETHOD. "disp_vbap_details
    ENDCLASS. "sales_order IMPLEMENTATION
    DATA : obj TYPE REF TO sales_order.
    START-OF-SELECTION.
      IF NOT p_matnr IS INITIAL.
        CREATE OBJECT obj EXPORTING vbeln = p_vbeln
        matnr = p_matnr.
      ELSE.
        CREATE OBJECT obj EXPORTING vbeln = p_vbeln.
      ENDIF.
      CALL METHOD obj->get_vbap_details.
      CALL METHOD obj->disp_vbap_details.
    *& report ziga_abapobjects_asgn01 *
      REPORT ziga_abapobjects_asgn01 .
      PARAMETER : p_matnr LIKE mara-matnr.
    * CLASS lcl_material DEFINITION
    CLASS lcl_material DEFINITION.
      PUBLIC SECTION.
        DATA: v_matnr TYPE mara-matnr.
        METHODS : constructor IMPORTING matnr TYPE mara-matnr,
        get_material_description.
      PRIVATE SECTION.
        DATA : v_maktx TYPE makt-maktx.
    ENDCLASS. "lcl_material DEFINITION
    * CLASS lcl_material IMPLEMENTATION
    CLASS lcl_material IMPLEMENTATION.
      METHOD get_material_description.
        CLEAR v_maktx.
        SELECT SINGLE maktx INTO v_maktx
        FROM makt
        WHERE matnr = v_matnr AND
        spras = 'E'.
      ENDMETHOD. "get_material_description
      METHOD constructor.
        CLEAR v_matnr.
        v_matnr = matnr.
      ENDMETHOD. "constructor
    ENDCLASS. "lcl_material IMPLEMENTATION
    DATA : obj TYPE REF TO lcl_material.
    START-OF-SELECTION.
      CREATE OBJECT obj EXPORTING matnr = p_matnr.
      CALL METHOD obj->get_material_description.
      prg3)
      report ziga_abapobjects_asgn01 .
      PARAMETER : p_matnr LIKE mara-matnr.
    * CLASS lcl_material DEFINITION
    CLASS lcl_material DEFINITION.
      PUBLIC SECTION.
        METHODS : constructor IMPORTING matnr TYPE mara-matnr,
        write_material_desc.
        CLASS-METHODS : class_constructor.
      PRIVATE SECTION.
        CLASS-DATA: v_matnr TYPE mara-matnr.
        DATA : v_maktx TYPE makt-maktx.
        METHODS : get_material_description.
    ENDCLASS. "lcl_material DEFINITION
    * CLASS lcl_material IMPLEMENTATION
    CLASS lcl_material IMPLEMENTATION.
      METHOD get_material_description.
        CLEAR v_maktx.
        SELECT SINGLE maktx INTO v_maktx
        FROM makt
        WHERE matnr = v_matnr AND
        spras = 'E'.
      ENDMETHOD. "get_material_description
      METHOD constructor.
        WRITE :/ 'Inside Instance Constructor'.
        CLEAR v_matnr.
        v_matnr = matnr.
        CALL METHOD get_material_description.
      ENDMETHOD. "constructor
      METHOD write_material_desc.
        WRITE :/ 'Material Description :', v_maktx.
      ENDMETHOD.                    "write_material_desc
      METHOD class_constructor.
        WRITE :/ 'Inside Static Constructor'.
      ENDMETHOD.                    "class_constructor
    ENDCLASS. "lcl_material IMPLEMENTATION
    DATA : obj TYPE REF TO lcl_material,
    obj1 TYPE REF TO lcl_material.
    START-OF-SELECTION.
      CREATE OBJECT obj EXPORTING matnr = p_matnr.
      CALL METHOD obj->write_material_desc.
      CREATE OBJECT obj1 EXPORTING matnr = '000000000000000110'.
      CALL METHOD obj1->write_material_desc.
      CALL METHOD obj->write_material_desc.
      prg4)
      report ziga_abapobjects_asgn01 .
      PARAMETER : p_matnr LIKE mara-matnr.
    * CLASS lcl_material DEFINITION
    CLASS lcl_material DEFINITION.
      PUBLIC SECTION.
        METHODS : constructor IMPORTING matnr TYPE mara-matnr,
        write_material_desc,
        get_material_description.
        CLASS-METHODS : class_constructor.
      PRIVATE SECTION.
        CLASS-DATA: v_matnr TYPE mara-matnr.
        DATA : v_maktx TYPE makt-maktx.
    ENDCLASS. "lcl_material DEFINITION
    * CLASS lcl_material IMPLEMENTATION
    CLASS lcl_material IMPLEMENTATION.
      METHOD get_material_description.
        CLEAR v_maktx.
        SELECT SINGLE maktx INTO v_maktx
        FROM makt
        WHERE matnr = v_matnr AND
        spras = 'E'.
      ENDMETHOD. "get_material_description
      METHOD constructor.
        WRITE :/ 'Inside Instance Constructor'.
        CLEAR v_matnr.
        v_matnr = matnr.
      ENDMETHOD. "constructor
      METHOD write_material_desc.
        WRITE :/ 'Material Description :', v_maktx.
      ENDMETHOD.                    "write_material_desc
      METHOD class_constructor.
        WRITE :/ 'Inside Static Constructor'.
      ENDMETHOD.                    "class_constructor
    ENDCLASS. "lcl_material IMPLEMENTATION
    DATA : obj TYPE REF TO lcl_material,
    obj1 TYPE REF TO lcl_material.
    START-OF-SELECTION.
      CREATE OBJECT obj EXPORTING matnr = p_matnr.
      CALL METHOD obj->get_material_description.
      CALL METHOD obj->write_material_desc.
      CREATE OBJECT obj1 EXPORTING matnr = '000000000000000110'.
      CALL METHOD obj1->get_material_description.
      CALL METHOD obj1->write_material_desc.
      CALL METHOD obj->get_material_description.
      CALL METHOD obj->write_material_desc.
      REPORT ziga_abapobjects_asgn01 .
      PARAMETER : p_matnr LIKE mara-matnr.
    * CLASS lcl_material DEFINITION
    CLASS lcl_material DEFINITION.
      PUBLIC SECTION.
        CLASS-METHODS : write_material_desc,
        get_material_description,
        class_constructor.
      PRIVATE SECTION.
        CLASS-DATA: v_matnr TYPE mara-matnr.
        CLASS-DATA: v_maktx TYPE makt-maktx.
    ENDCLASS. "lcl_material DEFINITION
    * CLASS lcl_material IMPLEMENTATION
    CLASS lcl_material IMPLEMENTATION.
      METHOD get_material_description.
        CLEAR v_maktx.
        SELECT SINGLE maktx INTO v_maktx
        FROM makt
        WHERE matnr = v_matnr AND
        spras = 'E'.
      ENDMETHOD. "get_material_description
      METHOD write_material_desc.
        WRITE :/ 'Material Description :', v_maktx.
      ENDMETHOD.                    "write_material_desc
      METHOD class_constructor.
        WRITE :/ 'Inside Static Constructor'.
        v_matnr = '000000000000000110'.
      ENDMETHOD.                    "class_constructor
    ENDCLASS. "lcl_material IMPLEMENTATION
    START-OF-SELECTION.
      CALL METHOD lcl_material=>get_material_description.
      CALL METHOD lcl_material=>write_material_desc.
    Arun Sambargi.

Maybe you are looking for