Menu

Permanent Users and BYOD not displaying

Help
nikonaum
2014-12-21
2014-12-27
  • nikonaum

    nikonaum - 2014-12-21

    Today I did un upgrade as described in the tutorial in radiusdesk site I patched the databases with all th patches in setup/Db directory and ran the php scripts in the directory but now I don't see any user or BYOD device in the admin panel. I'm using CentOS 6.6 and had fixed all the paths variables in the files to corespond to the CentOS directory structure.
    P.S. It's interesting that I had no items in Dynamic Pages and in NAS devices menus, but after some time all have showed up.
    P.S.2: It's not a browser issue cause I cleared the browser cache and was testing with Cromium in incognito mode.

     
  • Dirk van der Walt

    Hi,

    The behavior is as expected. There has been a major change in the Permanent Users.
    They are now in stored in their own permanent_users table.

    I'm in the process of writing a upgrade script which will:

    • Update the devices table and add the permanent_users table
    • Read all the existing Permanent Users stored in the users table and add them to the permanent_users table.
    • Remove the existing Permanent Users stored in the users table.
    • Remove the columns in the users table not needed.

    Will keep you posted once they are finished.

    Cheers

     
  • nikonaum

    nikonaum - 2014-12-22

    @Dirk, thanks for your quick reply.
    I'm not around my hotspots but I think that they are working with the old users, at least I'm seeing users in activity monitor. If so I'll wait for the patch/update and won't revert to the previous installation (I have a backup).
    P.S. I would like more detailed explanation to the database update instractions in the upgrade tutorial, especially all the database pathes and scripts. The order of applying the patches and so on.
    And once again: THANKS!

     
  • Dirk van der Walt

    Hi,

    Try these instructions:

    http://www.radiusdesk.com/getting_started/update_ubuntu_nginx

    You'll probably only need to run the migrate script sandwiched between the two sql patches.

    Let us know how it went.

    Cheers

     
  • nikonaum

    nikonaum - 2014-12-23

    I wanted to post last night but sourceforge had some server plroblems.
    So, It went OK I updated the MySQL tables and ran the php script and now I can see the permenent users in the admin panel, but still, no BYOD devices in admin panel. I had 40 devices before the update but now I have no devices in the menu.

     
  • nikonaum

    nikonaum - 2014-12-26

    Today I had some time for playing with Rdesk and found out that I have noting in devices table in rd database. In my backed up database I had 57 devices but now noting. Apperantly something in the update process had deleted all in this table. I tried to reinsert the values of the table devices from my backup but I have this error message in the chromium developer tools:
    {"code":"500","url":"\/cake2\/rd_cake\/devices\/index.json?_dc=1419601981740&page=1&start=0&limit=50&token=*&sel_language=4_4","name":"SQLSTATE[42S22]: Column not found: 1054 Unknown column 'Device.permanent_user_id' in 'on clause'","error":{"errorInfo":["42S22",1054,"Unknown column 'Device.permanent_user_id' in 'on clause'"],"queryString":"SELECT COUNT() AS count FROM rd.devices AS Device LEFT JOIN rd.permanent_users AS PermanentUser ON (Device.permanent_user_id = PermanentUser.id) WHERE 1 = 1"}}
    P.S. I deliberetly wiped out my token.

     
  • Dirk van der Walt

    Hi,

    Can you please check if you did this part:

    After you ran the migration script, run the rd_new_permanent_users_after_migration.sql patch to remove the unused columns.

    On this URL:

    http://www.radiusdesk.com/getting_started/update_ubuntu_nginx

    There is this bit that rename the devices table's user_id column in the sql patch:

    if exists (select * from information_schema.columns where column_name = 'user_id' and table_name = 'devices' and table_schema = 'rd') then
        alter table devices CHANGE `user_id` `permanent_user_id` int(11);
    end if;
    

    From the output it seems this part of the patch did not happen.

    Regards

     
  • nikonaum

    nikonaum - 2014-12-26
    1. I re-did my update but still no luck with BYOD manager. Some of the sql patches wiped my devices table and I deleted all my devices.
    2. Tried to add new device and It hangs when I press NEXT button. And gives this error:
    Notice (8): Undefined index: permanent_user_id [APP/Model/Device.php, line 81]

    {"success":true}

    1. When I refresh the BYOD manager I have no devices in view and the following message in Chromium Developer Tool:

    Notice (8): Undefined index: User [APP/Controller/DevicesController.php, line 174]{"items":[{"id":"5","user":null,"permanent_user_id":null,"name":"c4-43-8f-f3-c7-e2","description":"Nikolay Naumov Nexus 5","realm":"SWU","profile":"8M","profile_id":"14","perc_time_used":null,"perc_data_used":null,"active":true,"last_accept_time":null,"last_accept_nas":null,"last_reject_time":null,"last_reject_nas":null,"last_reject_message":null,"notes":false,"update":true,"delete":true}],"success":true,"totalCount":1}

     
  • nikonaum

    nikonaum - 2014-12-27

    I found what the problem was. I did an update according to the procedure but in order to save some time I just svn the rd_cake and used the php migration scripts and the sql patches without changing the other scripts in the webroot rd_cake dir, thinking that they were newly enough because I updated them on 21st of December. But the case was that that Dirk added the php and sql migration scripts and also has done changes to the other php files of the web application, which I was not aware of and that's why I had this errors in administration's web panel when adding BYODs.
    All fine now, except that I has to reinsert all my BYOD devices cause something during the update procedure deleted all records in the devices table of the database. Maybe I did something wrong but I'm not sure, never mind. The important thing is that all work fine now. I'M HAPPY.

     

Log in to post a comment.