In 2014, Mr. Santiago moved to Alaska and joined the Alaska Army National Guard. He got a job as a security guard and found a girlfriend 14 years his senior. A few months ago, they had a baby; a law enforcement official said it was not clear whether that was the same child that he brought with him to the F.B.I. office in November.

In January 2016, the girlfriend told the police that Mr. Santiago had flown into a rage while she was using the bathroom, broke down the bathroom door and was “strangling her and smacking her in the side of the head” while screaming at her, according to a criminal complaint filed against him. A month later, he was charged with violating a court order to stay away from his girlfriend after the police found that he had been living with her again.

In March, a deferred judgment was entered in the case, meaning that it could be dismissed if he stayed out of trouble, but the signs of unrest continued.

Chief Tolley said that once in March and twice in October, Mr. Santiago was the subject of domestic disturbance calls, but each time, officers lacked the basis for making an arrest.

In August, Mr. Santiago, who had reached the rank of private first class and had won several commendations for his earlier National Guard service — including the Army Good Conduct Medal — was discharged by the Alaska Guard for “unsatisfactory performance.”

Despite the disturbing nature of the episode with the F.B.I. in November, it did not land Mr. Santiago on any law enforcement watch lists or on the federal “no-fly” list. Neither did it impede his right to possess a gun.

At a news conference on Saturday in Anchorage, officials with the F.B.I. and local law enforcement said that although Mr. Santiago was clearly incoherent during his encounter with F.B.I. agents, he was not deemed to be threatening.