How To install a NAV Application Server (NAS)?

2

Comments

  • krikikriki Member, Moderator Posts: 9,115
    I added some comment where you can put some code:
    CGStarted := FALSE;
    ParamStr := NASID;
    REPEAT
      SepPosition := STRPOS(ParamStr,',');
      IF SepPosition > 0 THEN
        Parameter := COPYSTR(ParamStr,1,SepPosition - 1)
      ELSE
        Parameter := COPYSTR(ParamStr,1);
      IF Parameter = 'CG' THEN BEGIN
        BizTalkNASStartup.RUN;
        CGStarted := TRUE;
      END;
    //> START  
      IF Parameter = 'YOUR CODE' THEN BEGIN
        // Your code
      END;
    //< START  
      ParamStr := COPYSTR(ParamStr,SepPosition + 1);
    UNTIL SepPosition = 0;
    
    IF NOT CGStarted THEN BEGIN
      NASMgt.SetNASID(NASID);
      WORKDATE := 0D;
    
      IF NASSetup.GET(NASID) THEN BEGIN
        IF NASMgt.GetSendMail THEN BEGIN
          MailHandler.RUN;
          MailHandler.StartCountDown(2000);
        END;
        IF NASMgt.GetPerformSynch THEN
          MsgDispatcher.RUN;
        IF NASMgt.GetPerformRequests THEN
          RequestHandler.RUN;
      END ELSE
        ERROR(
          Text018,
          NASSetup.TABLECAPTION,
          NASID);
    END;
    
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • zaczac Member Posts: 29
    Thanks for you assistance Kriki. You were very helpful.
  • dtruppidtruppi Member Posts: 9
    Hi Kriki,

    thank you for your huge contribute.

    Did you ever experience nassql.exe taking 50% of CPU use?
    I run the service with 2 parameter:
    GTS: a single istance c.u. that triggers every 10 minutes.
    JOBQUEUE: every 1.00 am of the day perform a c.u.

    The CPU use with each single parameter is ok, but when i combine them suddendly it raises to 50% and doesn’t go down.

    Any suggestion?
    Microsoft Certified Trainer since 2007

    Check out my NAV blog http://opennav.wordpress.com/
  • krikikriki Member, Moderator Posts: 9,115
    I haven't had that issue.
    I would create a logging-table in which I would write what the codeunits are doing.
    When starting the job, I would insert a record and COMMIT it and then start the job. At the end of the job I would insert that it finished with a COMMIT. And see what happens.

    Another possibility : why don't you put the GTS-logic in the jobqueue? So you don't need its singleinstance anymore to trigger it.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • dtruppidtruppi Member Posts: 9
    Another possibility : why don't you put the GTS-logic in the jobqueue? So you don't need its singleinstance anymore to trigger it.

    It's what i'm doing... :)

    I'll tell you if it worked!
    Microsoft Certified Trainer since 2007

    Check out my NAV blog http://opennav.wordpress.com/
  • navuser1navuser1 Member Posts: 1,329
    Deal all,

    I have a Native Server on Windows Server 2003 & I want to install NAS on that Platform.
    Will it work ???

    Kindly reply.
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    Yes.
    You just need to use nas.exe and not nassql.exe and use the same type of connection parameters as for the client.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • navuser1navuser1 Member Posts: 1,329
    kriki wrote:
    Yes.
    You just need to use nas.exe and not nassql.exe and use the same type of connection parameters as for the client.


    Thanks for Instant reply.
    Now or Never
  • navuser1navuser1 Member Posts: 1,329
    I could not start Nas service & it show me the below error screen


    what is the reason behind it ???
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    You need to give a windows login to the service that has also permission to use NAV (so you need also give permissions to that Windows user in the NAV permissions.
    An easy way of testing is login in Windows with that Windows user. Start NAV using Windows authentication. If you can enter NAV, the NAS should be ok.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • navuser1navuser1 Member Posts: 1,329
    kriki wrote:
    You need to give a windows login to the service that has also permission to use NAV (so you need also give permissions to that Windows user in the NAV permissions.
    An easy way of testing is login in Windows with that Windows user. Start NAV using Windows authentication. If you can enter NAV, the NAS should be ok.

    Thnx for quick reply.

    I can enter into Db thru window login but thru it I can not start the Service. Plz help.
    Now or Never
  • navuser1navuser1 Member Posts: 1,329
    Event Viewer gives me below error message :

    The description for Event ID ( 20005 ) in Source ( BACKUP-CLASSIC ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer. You may be able to use the /AUXSOURCE= flag to retrieve this description; see Help and Support for details. The following information is part of the event:
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    Is that the complete description?
    Seems to be missing something.

    Entering in Nav with that user using windows logging is just to be sure that the security in NAV is ok.
    The service you need to start using a administrator on the machine.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • navuser1navuser1 Member Posts: 1,329
    kriki wrote:
    Is that the complete description?
    Seems to be missing something.

    Warring event viewr message is :
    The description for Event ID ( 20010 ) in Source ( BACKUP-SQL ) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer. You may be able to use the /AUXSOURCE= flag to retrieve this description; see Help and Support for details. The following information is part of the event: You must specify which SQL Server and database you want to connect to when you start up the Navision Application Server.

    The manual Installation and System Management contains a list of the correct program properties.


    Entering in Nav with that user using windows logging is just to be sure that the security in NAV is ok.
    The service you need to start using a administrator on the machine.

    Ok.
    Now or Never
  • navuser1navuser1 Member Posts: 1,329
    The Service runs under the NT Authority\NetworkService Login.
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    You need to change the user of the service to the Windows user that has access to NAV.
    "Authority\NetworkService Login" has no access to NAV.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • navuser1navuser1 Member Posts: 1,329
    Thank Kriki.

    I have installed the NAS thru Domain Administrator but it also unable run the Service.
    What can I do ? Plz reply.
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    Go in the properties of the service.
    1) In the general tab, the "Path to executable" must point to the nas.exe for native DB and nassql.exe for the SQL DB. Are you using the correct one?
    2) in the Log on tab, you need to change the account to an account that has acces in the NAV DB. (Network Service has no access).
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • navuser1navuser1 Member Posts: 1,329
    kriki wrote:
    Go in the properties of the service.
    1) In the general tab, the "Path to executable" must point to the nas.exe for native DB and nassql.exe for the SQL DB. Are you using the correct one?

    "C:\Program Files\Microsoft Business Solutions-Navision\Application Server\nas.exe"
    I'm using Native DB.
    2) in the Log on tab, you need to change the account to an account that has acces in the NAV DB. (Network Service has no access).

    I'm using Domain Administrator ID to login to the DB. DB has a Window user for the same.
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    No. you are NOT using the domain administrator. You are using the server administrator. That is a completely different thing.
    Instead of using ".\administrator", you should use "YourDomain\administrator".
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • navuser1navuser1 Member Posts: 1,329
    Thaks Kriki...
    Atlast It runs with my window login account.
    Can you tell one thing :
    how much will it take to execute the function(ID=99) of the Codeuint 1 ?

    I mean what is the time limit between two excecution of function(ID=99) of the Codeuint 1 .
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    Function with ID 99 in codeunit 1 is only lauched once at the start of the NAS. It launches the code in that function and then finishes, never to enter again in that function.

    The trick is to let execute a singleinstance codeunit and configure something that can be triggered by outside processes (like a timer event or a MessageQueue event).
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • navuser1navuser1 Member Posts: 1,329
    kriki wrote:
    Function with ID 99 in codeunit 1 is only lauched once at the start of the NAS. It launches the code in that function and then finishes, never to enter again in that function.

    The trick is to let execute a singleinstance codeunit and configure something that can be triggered by outside processes (like a timer event or a MessageQueue event).

    Thank you...
    actually I'm want kill those session which are idle for more than 1 hour.
    To do so I have created a processonly report on session table.

    In this report I have filtered(DataItemTableView) records whose have idle time more than hour. And delete those records on Session - OnAfterGetRecord() trigger.


    If you have any example on timer event or a MessageQueue event then kindly share it.
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    Check this how-to. The last lines have an example.
    And for killing idle sessions, there is another how-to : http://www.mibuso.com/howtoinfo.asp?FileID=18 (with inside another example of the timer event).
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • navuser1navuser1 Member Posts: 1,329
    Is NAS occupied a User session ??
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    NAS's must be licensed separately. But each license comes with 1 NAS.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • navuser1navuser1 Member Posts: 1,329
    I’m working with client license & see in the Session Tab of the Database Information Window that Current Sessions = 70 & Licensed Sessions = 71

    What does it mean?

    I have seen that more than 70 users can not work simultaneously in the Database. Then why does database Information window show Licensed Sessions =71 in its Session Tab?

    Is it one session for NAS??

    Kindly reply. :-k
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    Licensing in itself is separate for users and NAS's.
    But when a count of the connected users is done, they are counted together.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


  • navuser1navuser1 Member Posts: 1,329
    kriki wrote:
    Licensing in itself is separate for users and NAS's.
    But when a count of the connected users is done, they are counted together.

    Thank you.
    What is the meaning of Current Sessions & Licensed Session ??

    Kindly reply.
    Now or Never
  • krikikriki Member, Moderator Posts: 9,115
    Current sessions: the number of sessions in use at the moment you opened the form
    Licensed sessions: the maximum number of sessions you can have open at any moment. This is the limit imposted by your license.
    Regards,Alain Krikilion
    No PM,please use the forum. || May the <SOLVED>-attribute be in your title!


Sign In or Register to comment.