Hi wise monks. This is a peculiar situation where I can run this code in windows activePerl(5.8)/strawberry perl(5.24.0) with no issues but when I try to run it in linux, I get an error: method nas:list_task has returned an error: Can't use string ("1") as an ARRAY ref while "strict refs" in use at (re_eval 127) line 1. Linux perl version is 5.10.1. Can you provide some insights as to why this might be the issue?

I took a datadump in Windows of the returned result:

$VAR1 = bless( [ [ bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:00:45 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '46', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:00 MST 20 +16', 'scheduleTaskID' => '46812861', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '4281', 'succeededChildCount' => '', 'runType' => 'Parallel', 'pendingChildCount' => '', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:00:45 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:00:35 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '35', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:00 MST 20 +16', 'scheduleTaskID' => '46812881', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '4751', 'succeededChildCount' => '', 'runType' => 'Parallel', 'pendingChildCount' => '', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:00:35 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:05:28 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '0', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '329', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:00 MST 20 +16', 'scheduleTaskID' => '46812891', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '4781', 'succeededChildCount' => '0', 'runType' => 'Parallel', 'pendingChildCount' => '1', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:05:28 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '0', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '3', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => '', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '', 'createDate' => 'Mon Dec 05 18:36:29 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Thu Dec 08 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Thu Dec 08 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '1901', 'csvData' => '', 'startDate' => '', 'scheduleTaskID' => '46741711', 'approvalPriority' => '', 'status' => '1', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '', 'succeededChildCount' => '', 'runType' => 'Parallel', 'pendingChildCount' => '', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:00:00 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '0', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:05:31 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46741711', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '1', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '331', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '1901', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:00 MST 20 +16', 'scheduleTaskID' => '46812831', 'approvalPriority' => '', 'status' => '12', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '', 'succeededChildCount' => '11', 'runType' => 'Parallel', 'pendingChildCount' => '0', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:05:32 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:00:06 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '0', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '6', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:01 MST 20 +16', 'scheduleTaskID' => '46812931', 'approvalPriority' => '', 'status' => '3', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '7081', 'succeededChildCount' => '0', 'runType' => 'Parallel', 'pendingChildCount' => '1', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:00:06 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:00:21 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '0', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '21', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:01 MST 20 +16', 'scheduleTaskID' => '46812941', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '7501', 'succeededChildCount' => '0', 'runType' => 'Parallel', 'pendingChildCount' => '1', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:00:21 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:00:19 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '0', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '19', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:01 MST 20 +16', 'scheduleTaskID' => '46812951', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '7511', 'succeededChildCount' => '0', 'runType' => 'Parallel', 'pendingChildCount' => '1', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:00:19 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:00:21 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '0', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '21', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:01 MST 20 +16', 'scheduleTaskID' => '46812961', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '7521', 'succeededChildCount' => '0', 'runType' => 'Parallel', 'pendingChildCount' => '1', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:00:21 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:02:30 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:01 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +01 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '0', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:01 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '150', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:01 MST 20 +16', 'scheduleTaskID' => '46812981', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '8931', 'succeededChildCount' => '0', 'runType' => 'Parallel', 'pendingChildCount' => '1', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:02:30 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:00:20 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:01 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +01 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '0', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:01 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '20', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:01 MST 20 +16', 'scheduleTaskID' => '46812971', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '7531', 'succeededChildCount' => '0', 'runType' => 'Parallel', 'pendingChildCount' => '1', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:00:20 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:05:04 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '0', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '305', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:00 MST 20 +16', 'scheduleTaskID' => '46812901', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '4791', 'succeededChildCount' => '0', 'runType' => 'Parallel', 'pendingChildCount' => '1', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:05:04 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:05:16 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '0', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '316', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:00 MST 20 +16', 'scheduleTaskID' => '46812911', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '4801', 'succeededChildCount' => '0', 'runType' => 'Parallel', 'pendingChildCount' => '1', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:05:16 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ), bless( { 'reservedDurationType' => '0', 'runningChildTaskId' => '', 'approvalUsers' => '', 'expensive' => '1', 'subTask' => '-1000', 'failureType' => '', 'approveByDate' => 'Tue Dec 06 06:00:00 MS +T 2016', 'systemTask' => '0', 'repeatType' => '1', 'taskCustom3' => '', 'deviceDataID' => '', 'completeDate' => 'Wed Dec 07 06:05:15 MST + 2016', 'result' => '-', 'taskType' => 'com.rendition.dib.CustomAct +ionsTask', 'repeatEndDate' => '', 'messageTo' => '', 'taskCustom1' => '', 'runASAP' => '0', 'repeatWeekday' => '', 'ticketNumber' => '', 'taskUserID' => '201', 'siteID' => '', 'parentTaskID' => '46812831', 'createDate' => 'Wed Dec 07 06:00:00 MST 2 +016', 'userGeneratedChange' => 'true', 'reservationEndDate' => 'Wed Dec 07 07:00: +00 MST 2016', 'coreID' => '1', 'saveTask' => 'true', 'priority' => '3', 'failedChildCount' => '0', 'comments' => '-', 'taskData' => '-', 'retryCount' => '0', 'tag' => '', 'taskCustom2' => '', 'scheduleDate' => 'Wed Dec 07 06:00:00 MST + 2016', 'stopOnFail' => '0', 'durationStr' => '60', 'taskCustom4' => '', 'taskName' => 'TGreenLeeCiscoSwitchGet', 'duration' => '315', 'approvalStatus' => '2', 'repeatCount' => '', 'deviceGroupID' => '', 'csvData' => '', 'startDate' => 'Wed Dec 07 06:00:00 MST 20 +16', 'scheduleTaskID' => '46812921', 'approvalPriority' => '', 'status' => '2', 'repeatInterval' => '', 'saveFavoriteLink' => 'false', 'deviceID' => '4811', 'succeededChildCount' => '0', 'runType' => 'Parallel', 'pendingChildCount' => '1', 'taskCustom5' => '', 'saveTemplate' => 'false', 'lastModifiedDate' => 'Wed Dec 07 06:05:15 + MST 2016', 'subTasks' => '', 'csvGroupTask' => '0', 'taskCustom6' => '', 'reservedDuration' => '3600', 'retryInterval' => '300', 'resultConfigID' => '' }, 'Opsware::NAS::Client::ScheduleTaskVO_6_0 +_x' ) ], { '-soaperror' => 0, '-rows' => 14, '-statuscode' => '200', '-success' => 1, '-soapetext' => '', '-datatype' => 'collection:ScheduleTaskVO', '-statustext' => '200' } ], 'Opsware::NAS::Client::Result' );

#!/usr/bin/perl use Getopt::Long; use Pod::Usage; use Carp; use POSIX qw/strftime/; use Data::Dumper; use strict; #Export NA Library use Opsware::NAS::Client; #Declare Login Variables my($user,$pass,$host) = ('someuser', 'somepwd', 'somehost'); my $dttm = strftime('%Y:%m:%d:00:00:00',localtime); my $Diag_Date = $dttm; #Options GetOptions( "user=s" => \$user, "pass=s" => \$pass, "host=s" => \$host, 'help|h|?' => \my $help) or pod2usage(2); pod2usage(1) if $help; # open a CLI session my $nas = Opsware::NAS::Client->new(); my $res = $nas->login(-user => $user, -pass => $pass, -host => $host); #Handling login errors unless ($res->ok()) { printf STDERR ("*** error: %s\n", $res->error_message()); printf STDERR ("Did you supply valid Credentials?\n"); printf STDERR ("Please verify User/Password.\n"); exit(1); } my @listoftasks=("getSwitches","getFirewalls"); foreach my $specificTask (@listoftasks) { my $tasklist = $nas ->list_task( start => $Diag_Date, name => $specificTask, type => "Run Command Script" ); print Dumper($tasklist); }; $nas->logout(); # clean up undef $nas; #Inform Status print "\n\n\rStatus: Done!\n\n"; exit(0);

In reply to Can't use string ("1") as an ARRAY ref while "strict refs by seekinghelp12

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.